|
|
sybperl-l Archive
Up Prev Next
From: Michael Peppler <mpeppler at peppler dot org>
Subject: Bug in Sybase::BLK
Date: Dec 5 2007 7:11PM
There is a bug in Sybase::BLK that shows up in certain circumstances
when it is used against a 15.0.2 or later ASE.
Because the system tables now use DOL locking, there is no implicit
order of returned rows, so the query that fetches the columns and the
data types of the target table can return data in the wrong order.
Here is a patch:
$ diff -c BLK.pm~ BLK.pm
*** BLK.pm~ Sun Mar 20 20:50:59 2005
--- BLK.pm Wed Dec 5 10:05:12 2007
***************
*** 669,674 ****
--- 669,675 ----
from $db.dbo.syscolumns c, $db.dbo.systypes t
where c.id = object_id('$db.$user.$table')
and c.usertype *= t.usertype
+ order by c.colid
", "ARRAY");
return [ @arr ];
Michael
--
Michael Peppler - Peppler Consulting SaRL
mpeppler@peppler.org - http://www.peppler.org
Sybase DBA/Developer - TeamSybase: http://www.teamsybase.com
Sybase on Linux FAQ - http://www.peppler.org/FAQ/linux.html
|