Hi
I had some trouble figurering out how to set up PostgreSQL. Specially the 'dsn' was hard to guess.
I wrote a simple description of how I did it: http://www.sslug.dk/~chlor/phpwiki-pgsql-install
If someone find it usefull I will write it with more details.
/hans
I did something similar, using PosgreSQL/Apache/PHP on Cygwin. My connect string looks like this:
'dsn' => 'pgsql://unix(/tmp/.s.PGSQL.5432)/phpwiki',
Is the socket() in your connect string a way to simplify this?
In index.php I wrote: 'dsn' => 'pgsql://user:pass@socket()/db',
The word "socket" is a string which is NOT "tcp". Look in lib/pear/DB.php for "tcp".
"socket", "unix" or "foo" is good as long as it is not "tcp".
I think your solution is much better. I'll use that one. Thanks.
Log in to post a comment.
Hi
I had some trouble figurering out how to set up PostgreSQL.
Specially the 'dsn' was hard to guess.
I wrote a simple description of how I did it:
http://www.sslug.dk/~chlor/phpwiki-pgsql-install
If someone find it usefull I will write it with more details.
/hans
I did something similar, using PosgreSQL/Apache/PHP on Cygwin. My connect string looks like this:
'dsn' => 'pgsql://unix(/tmp/.s.PGSQL.5432)/phpwiki',
Is the socket() in your connect string a way to simplify this?
In index.php I wrote:
'dsn' => 'pgsql://user:pass@socket()/db',
The word "socket" is a string which is NOT "tcp".
Look in lib/pear/DB.php for "tcp".
"socket", "unix" or "foo" is good as long as it is not "tcp".
I think your solution is much better. I'll use that one.
Thanks.