From: | Maciek Sakrejda <msakrejda(at)truviso(dot)com> |
---|---|
To: | dexdyne <from_postgresql_forum(at)dexdyne(dot)com> |
Cc: | pgsql-jdbc(at)postgresql(dot)org |
Subject: | Re: time zone setting. |
Date: | 2011-08-24 17:27:37 |
Message-ID: | CAH_hXRZLOF=ZBGip1kY36ciRHBPDzcw4hZHMvEAEXEqPKyvCrA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
> in front of some other queries, and they will operate as I expect. In fact I
> find the change persist across multiple PgAdmin queries, so it is obviously
> a "session setting"
Right (you can use SET LOCAL for this-transaction-only changes).
> But I can't put the "set time zone" stretring on the front of a jdbc
> preparedStatement - it just barfs.
You can't just prepend it to the statement text because JDBC prepared
statements need to correspond to a single SQL statement. But you
should be able to issue a separate "set time zone" statement (either
normal or prepared) and get the session behavior you see through
pgAdmin. Does that not work? What is the error?
---
Maciek Sakrejda | System Architect | Truviso
1065 E. Hillsdale Blvd., Suite 215
Foster City, CA 94404
(650) 242-3500 Main
www.truviso.com
From | Date | Subject | |
---|---|---|---|
Next Message | Oliver Jowett | 2011-08-24 21:42:44 | Re: time zone setting. |
Previous Message | dexdyne | 2011-08-24 10:25:31 | time zone setting. |