On 4/14/06, Jesse Brown <[EMAIL PROTECTED]> wrote:
> As a side note, I've noticed that mysql 'bigint' gets converted to a 20 byte
> scalar, which is about as correct as it can get on 32bit machines. However, on
> perls with 64 bit integers, it should just be an int type. (more and more
> common with x64 arch's)
>
> What is the prevailing opinion about things like this?

Are MySQL's bigints really limited to 64 bits, or are they arbitrary
precision?  If they're really 64-bit, then what I'd need to make RDBO
do the right thing is a way to determine if perl itself is compiled to
use 64-bit integers internally.  If I can detect that, then I can
change the default column type mapping to map "bigint" to the Integer
column class instead of the BigInt class.

You can do this yourself right now, of course, using the
column_type_class() method of the metadata class.  If you're using the
default metadata class, then that'd be:

Rose::DB::Object::Metadata->column_type_class(
  bigint => 'Rose::DB::Object::Metadata::Column::Integer');

Put that call anywhere where it'll get run before you initialize your
first RDBO class to make all the bigint columns use the Integer column
class.

-John


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642
_______________________________________________
Rose-db-object mailing list
Rose-db-object@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rose-db-object

Reply via email to