Received: from magus.postgresql.org (magus.postgresql.org [87.238.57.229]) by mail.postgresql.org (Postfix) with ESMTP id C42D5A684DD for ; Mon, 21 May 2012 05:18:43 -0300 (ADT) Received: from mail-pb0-f46.google.com ([209.85.160.46]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1SWNp9-0001gZ-31 for pgsql-jdbc@postgresql.org; Mon, 21 May 2012 08:18:42 +0000 Received: by pbbrp8 with SMTP id rp8so6620051pbb.19 for ; Mon, 21 May 2012 01:18:22 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding :x-gm-message-state; bh=EL+e8IR9IJJIJZDPZeWEG+rsVhMjJES/wqNvMJj8BwU=; b=H25fn/5XlPRX/3GFBye+d4hCLZk0xwuZRBpDxuCQyuMB08BU4s7juCzOmqGAKPTQmu zpeXC8G4wdPiG3VjTpfVeONwqHd0jz4pojIHvgSuBpBnfQXcr/R6XTUNbgxyaUVOAgmX nOjPKJXw79rluxP06SnMxKqqkJ8Nv6sbLL7K6dGGI9o+1DUolEeuw2J4bBy6K6lgpWcP /t7wquytD3BE7EoTwVmzx0DRldyo6LyigDV228+MlqzxLHey1uQbC/h0VnPvLrJqtRJe m5PLBm2D6s0z7vxFn7lv3CkCzYf0hRXbySu6BehN3fvPgDby0V3mfAuqE1IPqeV4qvLz sEiA== Received: by 10.68.192.67 with SMTP id he3mr22197531pbc.114.1337588302806; Mon, 21 May 2012 01:18:22 -0700 (PDT) Received: from wallace.localnet (office1.postnewspapers.com.au. [150.101.171.128]) by mx.google.com with ESMTPS id qt8sm10388016pbc.62.2012.05.21.01.18.19 (version=SSLv3 cipher=OTHER); Mon, 21 May 2012 01:18:21 -0700 (PDT) Message-ID: <4FB9FA49.4070409@ringerc.id.au> Date: Mon, 21 May 2012 16:18:17 +0800 From: Craig Ringer User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:12.0) Gecko/20120430 Thunderbird/12.0.1 MIME-Version: 1.0 To: Mikko Tiihonen CC: pgsql-jdbc@postgresql.org Subject: Re: Patch: Add support for hstore extension - and map it to/from java.util.Map References: <4FAB8796.40904@nitorcreations.com> In-Reply-To: <4FAB8796.40904@nitorcreations.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Gm-Message-State: ALoCoQlrnkEvSrAI+JW0wHzCZiOZVtXa4Qgn4bQSkzQl0MpFSfaQ98qHIxSOpBKv8doqjLAGZ6hd X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201205/66 X-Sequence-Number: 22966 On 05/10/2012 05:17 PM, Mikko Tiihonen wrote: > Hi, > > Here is a patch to enable initial support for hstore in the jdbc driver. > > With the patch using ResultSet.getObject() on a hstore column and it > returns a HashMap > Similarly a Statement.setObject(Map will send the data > to backend using hstore format. That's absolutely brilliant, thankyou! Of course, now there's a `json' type that folks will probably use much of the time instead, not least because it should be easier to work with from JDBC. I doubt it'll be as efficient and fast as hstore for single-level key/value info though. -- Craig Ringer