Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 4CC2A9FA000 for ; Fri, 2 Nov 2007 17:05:17 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 04438-03 for ; Fri, 2 Nov 2007 17:05:04 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from hpsmtp-eml16.kpnxchange.com (hpsmtp-eml16.kpnxchange.com [213.75.38.116]) by postgresql.org (Postfix) with ESMTP id 95D319FA023 for ; Fri, 2 Nov 2007 17:05:07 -0300 (ADT) Received: from cpsmtp-eml109.kpnxchange.com ([213.75.84.109]) by hpsmtp-eml16.kpnxchange.com with Microsoft SMTPSVC(6.0.3790.1830); Fri, 2 Nov 2007 21:05:05 +0100 Received: from [192.168.1.6] ([86.84.82.159]) by cpsmtp-eml109.kpnxchange.com with Microsoft SMTPSVC(6.0.3790.1830); Fri, 2 Nov 2007 21:05:05 +0100 Message-ID: <472B8311.6080505@planet.nl> Date: Fri, 02 Nov 2007 21:05:37 +0100 From: Kees Kling User-Agent: Thunderbird 1.5.0.10 (X11/20070221) MIME-Version: 1.0 To: pgsql-jdbc@postgresql.org Subject: storing large arrays of floats Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 02 Nov 2007 20:05:06.0017 (UTC) FILETIME=[A96C5D10:01C81D8B] X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.001 tagged_above=0 required=5 tests=BAYES_50=0.001 X-Spam-Level: X-Archive-Number: 200711/2 X-Sequence-Number: 17757 HI I have to store an array of 50,000 floats in a postgres database. At firts I tried to store it as float[], but that take s to much time for jdbc to convert the data so that it can be stored in the database. Next I tried to store it as byte[] array in a BYTEA column. This worked ok, but when I inspect the data at the serverside the datasize increased with a factor 1,5 to 2 and I see a lot of escape(\0) characters. What I mean to do is storing the bunch of data and retrieving subselections of the data with the help of Plperl fucntions. Now I can't restore the data at serverside. What is the clue? Do I have to store the data with another function as "preparedstatement.setBytes" or must I use another columntype. Thanks Kees Kling