>>>>> "Alex" == Alex Pilosov <[EMAIL PROTECTED]> writes:

Alex> On 27 Jun 2001, Randal L. Schwartz wrote:
>> Nope.  Still fails on pack "C*", 128..255;  Works for pack "C*", 128
>> though.  Dies with
>> 
>> ERROR:  Unterminated quoted string
>> 
>> Something isn't being detected right.  It doesn't work
>> until it can handle pack "C*", 0..255, correct?
Alex> This is what I have, and it seems to work.

Alex> #!/usr/bin/perl

Alex>     use DBI qw(SQL_BINARY SQL_VARCHAR);

Alex>     my $dbh = DBI->connect("dbi:Pg:dbname=users", "sw", "sw",
Alex>       { RaiseError => 1 });
Alex>     $dbh->do("drop TABLE test");
Alex>     $dbh->do("CREATE TABLE test (a BYTEA)");
Alex>     my $insert = $dbh->prepare("INSERT INTO test VALUES (?)");
Alex>     my $x1=pack "C*", 0..255;
Alex>     $insert->bind_param(1, undef, SQL_BINARY); # necessary for BYTEA
Alex>     $insert->execute($x1);

Alex> Can you give me your code? and output from DBI_TRACE=2 yourscript?

Argh.  The install for DBD::Pg doesn't install the .so and .bs for some
reason if they're already there. :(  I had to manually delete
the installation .so and .bs, and then reinstall.  I'm glad I caught
the "not updated" during the fifth "make install" I typed. :)

So yes, with this patch, everything is great!  Thank you!

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<[EMAIL PROTECTED]> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!

Reply via email to