Solved the problem, here's one for the archives. Upgrade to the latest version of MDAC (currently 2.7).
.. The production server was still running an old version. Downloading the MDAC2.7 from microsoft and installing it solved the problems. If anyone wants me I'll be out the back hitting myself over the head with a plank of hardwood. Will Lotto Systems Administrator > -----Original Message----- > From: Will Lotto [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, 2 July 2002 12:42 PM > To: [EMAIL PROTECTED] > Cc: [EMAIL PROTECTED] > Subject: Unsigned Int / Signed Int issue when using MyODBC2.5 > > > G'day, > > I've got a problem with the ODBC driver for MySQL, in that > when I use an SQL select statement on a field of type > UNSIGNED INTEGER, the resulting recordset in asp uses SIGNED > INTEGER data types, so any data > 2^31 is dropped by asp. > > The offending code is as follows: > > > Set sqlCommand = Server.CreateObject("ADODB.Command") > sqlCommand.ActiveConnection = "MyDatabase" > sqlCommand.CommandText = "SELECT * FROM " & SQLTable & > " Where DataDate >= " & StartDate & " and DataDate <= " & > EndDate & " ORDER BY DataDate" > Set rs = sqlCommand.Execute > > The database design: > > mysql> describe SQLTable; > +----------+------------------+------+-----+---------+-------+ > | Field | Type | Null | Key | Default | Extra | > +----------+------------------+------+-----+---------+-------+ > | DataDate | int(10) unsigned | YES | | NULL | | > | DataIn | int(10) unsigned | YES | | NULL | | > | DataOut | int(10) unsigned | YES | | NULL | | > | Elapsed | int(10) unsigned | YES | | NULL | | > +----------+------------------+------+-----+---------+-------+ > 4 rows in set (0.00 sec) > > > Unfortunatly, whenever the data in any of the fields exceeds > 2,147,483,648 it is dropped from the resulting recordset. ... > And just to throw a spanner in the works, that code works > perfactly on our development PC, but not on the production server. > > Does anyone have any idea why this would be failing, or know > a better way to select the code and drop it into a recordset > (or array) in asp? > > Thanks for any help. > > Will Lotto > Systems Administrator > > > --------------------------------------------------------------------- > Before posting, please check: > http://www.mysql.com/manual.php (the manual) > http://lists.mysql.com/ (the list archive) > > To request this thread, e-mail <[EMAIL PROTECTED]> > To unsubscribe, e-mail > <[EMAIL PROTECTED]> > Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php > --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php