mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-15 16:38:54 +00:00
Fixed bug #52116 (pg_connect - how to use options)
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@304555 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
d25dd45e32
commit
29fd59a70b
1 changed files with 7 additions and 0 deletions
|
@ -60,6 +60,10 @@
|
|||
<parameter>service</parameter>. Which of these arguments exist depends
|
||||
on your PostgreSQL version.
|
||||
</para>
|
||||
<para>
|
||||
The <parameter>options</parameter> parameter can be used to set command line parameters
|
||||
to be invoked by the server.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
|
@ -103,6 +107,9 @@ $dbconn3 = pg_connect("host=sheep port=5432 dbname=mary user=lamb password=foo")
|
|||
$conn_string = "host=sheep port=5432 dbname=test user=lamb password=bar";
|
||||
$dbconn4 = pg_connect($conn_string);
|
||||
//connect to a database named "test" on the host "sheep" with a username and password
|
||||
|
||||
$dbconn5 = pg_connect("host=localhost options='--client_encoding=UTF8'");
|
||||
//connect to a database on "localhost" and set the command line parameter which tells the encoding is in UTF-8
|
||||
?>
|
||||
]]>
|
||||
</programlisting>
|
||||
|
|
Loading…
Reference in a new issue