hi all,
having some memory leak issues with my app and spi_exec_prepared.
checking the docs:
"Normally, spi_fetchrow should be repeated until it returns undef,
indicating that there are no more rows to read. The cursor is
automatically freed when spi_fetchrow returns undef. If you do not
wish to
th->bind_param(2,$md5sum);
> $sth->bind_param(3,$bin, { pg_type => PG_BYTEA });
> $sth->execute();
> }
>
>
> I hope this helps if you haven't figured it out yet
>
>
> On Saturday 22 August 2009 03:48:25 pm Daniel Verite wrote:
>> Nat
cute($id);
my $newref = $getall_sth->fetchrow_hashref;
my $newdata = $newref->{data};
print md5_hex($data).' ';
print '!' if md5_hex($data) ne md5_hex($newdata);
print '= '.md5_hex($newdata);
print "\n";
--
nathan
On Sat, Aug 22, 2009 at 9:17 AM, Dan
7ec965
nathan
On Fri, Aug 21, 2009 at 6:11 PM, Tim Landscheidt wrote:
> Nathan Jahnke wrote:
>
>> [...]
>> my $encodeddata = $data;
>> $encodeddata =~ s!(\\|[^ -~])!sprintf("\\%03o",ord($1))!ge; #prepare
>> data for bytea column storage
>
>> [...]
&
got some binary data that changes when i insert and retrieve it later
from bytea column:
http://nate.quandra.org/data.bin.0.702601051229191
running 8.3 on debian 5.0.
example:
root=# create database testdb;
CREATE DATABASE
root=# \c testdb
You are now connected to database "testdb".
testdb=# cr
Hi all,
Having some trouble today accessing tables in a database:
sample=# \l+
List of databases
Name| Owner | Encoding | Tablespace |Description
---+--+--++---
postgres | postgres | UTF8
Hi all,
Spent the last few hours searching but was unable to get a
satisfactory answer. Basically, if I do this:
my $arr = [1,2,3,4];
$_SHARED{test} = spi_prepare('update users set interest=$1 where
uid=2', 'int[]');
spi_exec_prepared($_SHARED{test}, $arr);
I get:
DBD::Pg::st execute failed: ER