Re: Question about passing array of a complex type from jdbc to plpgsql

From: Maciek Sakrejda <msakrejda(at)truviso(dot)com>
To: Vaclav Tvrdik <tvrdik(at)i3(dot)cz>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Question about passing array of a complex type from jdbc to plpgsql
Date: 2011-07-05 06:41:46
Message-ID: CAH_hXRYu6KKoTWB4aGVeFTC9X+BPL8wNaGC8OR52Xd_0edA=7w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

I've worked with arrays of UDTs a bit in the past, and have encoded
them to text and cast on the query side. This isn't exactly pretty,
but it works fine. Arrays have one set of syntax rules, UDTs a
slightly different set, and then you need to take into account
standard_conforming_strings (or at least work with the setting of
standard_conforming_strings that you expect, if you know it will be
consistent). Don't think about standard_conforming_strings until the
very last step--this keeps things simpler and should let you nest UDTs
and arrays arbitrarily deep. I can't find the relevant documentation
with a quick search, but if you point out what you think is
inconsistent maybe I can help explain.
---
Maciek Sakrejda | System Architect | Truviso

1065 E. Hillsdale Blvd., Suite 215
Foster City, CA 94404
(650) 242-3500 Main
www.truviso.com

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Heikki Linnakangas 2011-07-05 06:52:51 Re: Possible oversight in org.postgresql.xa.PGXAConnection.commitPrepared(Xid xid)
Previous Message Radosław Smogura 2011-07-05 06:12:59 Re: Possible oversight in org.postgresql.xa.PGXAConnection.commitPrepared(Xid xid)