agora inbox for pgsql-sql@postgresql.org
help / color / mirror / Atom feedFrom: Sebastien FLAESCH <sf@4js.com>
To: pgsql-sql@postgresql.org
Subject: Re: Determining the DATE format with libpq
Date: Fri, 25 Aug 2017 10:13:19 +0200
Message-ID: <a1236c41-584b-bbb1-b6ea-01d0dfffa000@4js.com> (raw)
In-Reply-To: <350a1d87-6abc-f149-9251-e28285504301@4js.com>
References: <46935bcd-5754-9deb-fc63-8162bcdd4c46@4js.com>
<16272.1503588417@sss.pgh.pa.us>
<350a1d87-6abc-f149-9251-e28285504301@4js.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-sql>
I appologize for my poor English...
I was just wondering about the overhead of a call to PQparameterStatus().
After some tests, it appears to be minor.
Anyway, thanks for your help!
Seb
On 08/24/2017 05:44 PM, Sebastien FLAESCH wrote:
> Whoooooo that's perfect!!!
>
> I hope it has not a big cost?
>
> Can I use this each time I fetch a result set?
>
> Even row by row with a server cursor?
>
> Seb
>
> On 08/24/2017 05:26 PM, Tom Lane wrote:
>> Sebastien FLAESCH <sf@4js.com> writes:
>>> Is there a way to know the current date format used in the SQL session?
>>> Ideally, we expect a libpq API.
>>
>> Use PQparameterStatus().
>>
>>> We cannot do a "SHOW DateStyle" each time we executing a SELECT!
>>
>> You don't have to --- the server automatically reports changes in the
>> value of that parameter.
>>
>> regards, tom lane
>>
>>
>
>
>
--
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-sql
view thread (5+ messages) latest in thread
Message-ID: <a1236c41-584b-bbb1-b6ea-01d0dfffa000@4js.com>
Permalink: ../a1236c41-584b-bbb1-b6ea-01d0dfffa000@4js.com/
Also on: postgresql.org/message-id/a1236c41-584b-bbb1-b6ea-01d0dfffa000@4js.com
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: sf@4js.com
Subject: Re: Determining the DATE format with libpq
In-Reply-To: <a1236c41-584b-bbb1-b6ea-01d0dfffa000@4js.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox