I had a look at this in the debugger and it is a byte order problem. Did you test it on a non Intel machine?
In ha_pbxt::get_auto_increment() the values passed in to table->next_number_field->cmp(() are
bigendian but the compare checks the table's db_low_byte_first which is 'true' and so the values are treated as littleendian.
int Field_long::cmp(const uchar *a_ptr, const uchar *b_ptr)
{
int32 a,b;
#ifdef WORDS_BIGENDIAN
if (table->s->db_low_byte_first)
{
a=sint4korr(a_ptr);
b=sint4korr(b_ptr);
}
I had a look at this in the debugger and it is a byte order problem. Did you test it on a non Intel machine?
In ha_pbxt: :get_auto_ increment( ) the values passed in to table-> next_number_ field-> cmp(() are
bigendian but the compare checks the table's db_low_byte_first which is 'true' and so the values are treated as littleendian.
int Field_long: :cmp(const uchar *a_ptr, const uchar *b_ptr) >s->db_ low_byte_ first) (a_ptr) ; (b_ptr) ;
{
int32 a,b;
#ifdef WORDS_BIGENDIAN
if (table-
{
a=sint4korr
b=sint4korr
}