Received: from localhost (maia-3.hub.org [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 1D1989FB222 for ; Sun, 8 Apr 2007 14:03:23 -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 25394-04 for ; Sun, 8 Apr 2007 14:03:13 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.4 Received: from py-out-1112.google.com (py-out-1112.google.com [64.233.166.178]) by postgresql.org (Postfix) with ESMTP id 96A6C9FB1C6 for ; Sun, 8 Apr 2007 14:03:19 -0300 (ADT) Received: by py-out-1112.google.com with SMTP id a73so864898pye for ; Sun, 08 Apr 2007 10:03:18 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=Xua+AeFC53A10+RymQzlmTiNuyj2giKAKFz+VyrVSrn0J6wsoxX/gCOx0nMq8O4mesWns3MbV0+HcNQBDPhlUdDUCuAAgUg1PtIUUHOEHOSthxv/dSfhlMMujxFta1ue72l8/WsMtEgEHLzNO4L+QvObUST00JYyvZxUFg1Dcd8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=dcgXEzsVI4XZR9XHH3enf0Ssg3BGSIrE49Jg+qxaOrdeBxl7GoR+POaXJfw6ehkdtubPGB53NmKsHhQd5GbcoyHF2o+bPILu33hQRfVDt4A84Ca34bHhaK2GCKhM2KHIp5LdbkpG52GetrSvwEl4V1PlQJgM1pGiWG6m1KE/gK8= Received: by 10.65.122.20 with SMTP id z20mr9938814qbm.1176051797313; Sun, 08 Apr 2007 10:03:17 -0700 (PDT) Received: by 10.64.112.5 with HTTP; Sun, 8 Apr 2007 10:03:17 -0700 (PDT) Message-ID: <5d0f60990704081003p615530acx86257a70bff33fa4@mail.gmail.com> Date: Sun, 8 Apr 2007 19:03:17 +0200 From: "Dirk Jagdmann" To: pgsql-sql@postgresql.org Subject: MD5 sums of large objects MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200704/92 X-Sequence-Number: 28092 Hello all together, I have a database containing lots of large objects. Now I'd like to compare large objects in my database and I thought of having a function which creates a hashsum (MD5, SHA-1 or whatever) of my large object, so I can use that in queries: create function lo_md5(id oid) returns text... Now I don't know if something like this is already included in the PostgreSQL distribution, could be found somewhere on pgfoundry or thirdly how to do it? If I have to program myself I would go for a C-language function which would use the libpq large-object functions to create the hashsums. -- ---> Dirk Jagdmann ----> http://cubic.org/~doj -----> http://llg.cubic.org