Received: from student.merz-akademie.de (73.ptr.merz-akademie.de [195.226.105.73] (may be forged)) by mail.postgresql.org (8.11.1/8.11.1) with ESMTP id eAEL4os60663 for ; Tue, 14 Nov 2000 16:04:50 -0500 (EST) (envelope-from alvar.freude@merz-akademie.de) Received: from merz-akademie.de (news.merz-akademie.de [195.226.105.70]) by student.merz-akademie.de (8.9.3/8.9.3) with ESMTP id WAA27566 for ; Tue, 14 Nov 2000 22:03:33 +0100 Message-ID: <3A11A99B.D3A0D0BE@merz-akademie.de> Date: Tue, 14 Nov 2000 22:07:39 +0100 From: Alvar Freude Organization: http://a-blast.org/ X-Mailer: Mozilla 4.7 [de] (WinNT; I) X-Accept-Language: de MIME-Version: 1.0 To: pgsql-interfaces@postgresql.org Subject: Getting real arrays from array fields in Perl Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Archive-Number: 200011/152 X-Sequence-Number: 188 Hello, i have created a table containing arrays like this: CREATE TABLE arraytest ( id SERIAL, array int8[], value text ) I use the DBI interface in Perl to handle the database. If i select arrays in the database, it returns strings instead of real Perl array refereneces: my $arrayref = $db_p->selectall_arrayref("SELECT * FROM arraytest"); use Data::Dumper; print Dumper($arrayref); The result is: $VAR1 = [ [ 1, '{23,24,25,26}', 'foo' ], [ 2, '{1,2,3,4}', 'bar' ] ]; I want a structure containing real arrayrefs like this: $VAR1 = [ [ 1, [ 23,24,25,26 ], 'foo' ], [ 2, [ 1,2,3,4 ], 'bar' ] ]; Is there an option to get the desired behaviour? I couldn't find anything in the documentation of Postgres and DBD::Pg. Thank you Alvar -- Alvar C.H. Freude | alvar.freude@merz-akademie.de Demo: http://www.online-demonstration.org/ | Mach mit! Blast-DE: http://www.assoziations-blaster.de/ | Blast-Dich-Fit Blast-EN: http://www.a-blast.org/ | Blast/english