Hi,

> However, on one of our servers, we have to run Postgres on a 
> port other than 5432. 

> It looks to me that in dbx_mysql.c, you can use the MySQL 
> "host:port/host:socket" syntax.  Is there any possibility 
> that this syntax or a variation of it could be used throughout
> dbx?  

You can indeed use the 'host:port' for mysql, as this is an accepted input
for the mysql_connect hostname. However, that syntax would not work for any
of the other databases.

Since the default pgsql portnumber is 5432 and that is the value that is
hardcoded in dbx_pgsql.c, wouldn't it be easier to just remove this part of
the connection-string from the c-file? That makes the patch trivial, while
allowing you to set the portnumber with environment variables (PGPORT=7890).

Since you read the source I assume you can compile it too, so you could
easily test if this works for you (I do not have a running postgresql here,
so testing is difficult), on systems with both a default portnumber and an
alternative portnumber.

Any comments on this solution instead of a host:port syntax?

Cheerio, Marc.

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to