Re: odbc_connect - urgent
| From: | iODBC Maintainer | Date: | Thu, 10 Jan 2008 21:08:42 +0000 |
| Subject: | Re: odbc_connect - urgent | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-44508@lists.php.net to get a copy of this message | ||
HI Gustavo,
Hi, im in serious problems. First sorry for bad english. Im try to connect with many servers to take some information, but when one of those is offline my script in php is fails and not proced. Did have any way to configure te odbc_connect timeout?? its take to many time to resolve take site is off or online. Im try to ping the server but sometimes the server of internet is not same the sql server.Unfortunately you cannot set the login timeout using the odbc_setoption like:
odbc_setoption ($conn, 1, 103 /*SQL_LOGIN_TIMEOUT*/, 30)since the current php odbc layer cannot handle setting connection parameters before making an actual connection. However most ODBC drivers do have some capabilities to adjust timeouts. Which driver are you using to connect to sql server? Patrick