diff options
| author | Magnus Hagander | 2012-11-30 06:09:18 +0000 |
|---|---|---|
| committer | Magnus Hagander | 2012-11-30 06:11:08 +0000 |
| commit | 65c3bf19fd3e1f6a591618e92eb4c54d0b217564 (patch) | |
| tree | 7007982b7862d52dec118f850a3da59a7bb76b74 /doc/src/sgml | |
| parent | 4af446e7cd0b37bb5d7fa9b73193c68e14239499 (diff) | |
Add libpq function PQconninfo()
This allows a caller to get back the exact conninfo array that was
used to create a connection, including parameters read from the
environment.
In doing this, restructure how options are copied from the conninfo
to the actual connection.
Zoltan Boszormenyi and Magnus Hagander
Diffstat (limited to 'doc/src/sgml')
| -rw-r--r-- | doc/src/sgml/libpq.sgml | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/doc/src/sgml/libpq.sgml b/doc/src/sgml/libpq.sgml index 255c5c1abb8..e7ad066fe51 100644 --- a/doc/src/sgml/libpq.sgml +++ b/doc/src/sgml/libpq.sgml @@ -496,6 +496,30 @@ typedef struct </listitem> </varlistentry> + <varlistentry id="libpq-pqconninfo"> + <term><function>PQconninfo</function><indexterm><primary>PQconninfo</></></term> + <listitem> + <para> + Returns the connection options used by a live connection. +<synopsis> +PQconninfoOption *PQconninfo(PGconn *conn); +</synopsis> + </para> + + <para> + Returns a connection options array. This can be used to determine + all possible <function>PQconnectdb</function> options and the + values that were used to connect to the server. The return + value points to an array of <structname>PQconninfoOption</structname> + structures, which ends with an entry having a null <structfield>keyword</> + pointer. All notes above for <function>PQconndefaults</function> also + apply to the result of <function>PQconninfo</function>. + </para> + + </listitem> + </varlistentry> + + <varlistentry id="libpq-pqconninfoparse"> <term><function>PQconninfoParse</function><indexterm><primary>PQconninfoParse</></></term> <listitem> |
