From: Jeff McKeon [mailto:[EMAIL PROTECTED]

> Query: 
> 
> insert into
> MIS.simcard(ID,ShipID,Service_Provider,SN,v1,v2,f1,d1,puk1,puk
> 2,pin1,pin
> 2,TwoStage,Status,DateAssigned,DateDisabled,UserID) 
> VALUES('NULL', '6889927707', '1', '8988169214000421398', 
> '881621456175',
> '', '', '881693156175', '62982149', '', '1111', '', '1307', '1',
> '1085508771', 'NULL', 'jsm');
> 
> Always results in a ShipID field value of "2147483647" instead of
> "6889927707"
> 
> Even if I just do a simple:
> 
> insert into MIS.simcard (ShipID) values ('6889927707');
> 
> It does the same darn thing.
> 
> ShipID is an Int(11) field
> Version 4.0.15
> 
> If I change the first digit of the input from a 6 to any 
> other digit, it
> gets entered correctly.  Any idea what is going on here!?
> 
> Version 4.0.15

The max value of INT is 2147483647, lower than the value you're inserting (even when 
unsigned, which is 4294967295). That's why that's what's getting inserted.

Manual page is here:
http://dev.mysql.com/doc/mysql/en/Numeric_type_overview.html

Try converting the column to a BIGINT, the signed max alone is 9223372036854775807.


-- 
Mike Johnson
Web Developer
Smarter Living, Inc.
phone (617) 886-5539

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to