Another weird thing, I inserted about 10,000 characters into the 
column, I can see them in the database using MicroSoft tools, but 
if I query in Perl I get the error below (which is the same if I 
insert/query a text column, which apparently doesn't have the varchar 
~8K limit), but for whatever reason the cfm query against the image 
column only gets the first 19 characters (haven't tried the cfm query 
with a text column yet).  The Perl output is:

DBD::ODBC::st fetchrow_array failed: [Microsoft][ODBC SQL Server 
Driver]String data, right truncation (SQL-01004)(DBD: s
t_fetch/SQLFetch (long truncated) err=1) at C:\temp\db2.ipl line 33.

My guess is that this has something to do with bind_param, maybe 
bind_param_inout, and I read the perldoc on DBI but couldn't figure 
out what I need to do about this.  How do I specify the type of a 
return parameter for a query (couldn't find an example)?  And since 
it's text, I shouldn't even have to specify a type - why is it getting 
truncated?

Thanks again,

   -John

my $sql = "select TextType from TestImage where TestImageID = 41";
my $sth = $dbh->prepare( $sql );
my $ret = $sth->execute();

while( my @data = $sth->fetchrow_array())
{
    print "SELECTED: " . Dumper( @data );
}

DBD::ODBC::st fetchrow_array failed: [Microsoft][ODBC SQL Server 
Driver]String data, right truncation (SQL-01004)(DBD: s
t_fetch/SQLFetch (long truncated) err=1) at C:\temp\db2.ipl line 33.








Reply via email to