Re: Interbase 5.6 error and php 4.0.4
| From: | Todd Cary | Date: | Wed, 03 Jan 2001 13:59:49 +0000 |
| Subject: | Re: Interbase 5.6 error and php 4.0.4 | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-5558@lists.php.net to get a copy of this message | ||
Greg -
I am running Interbase 6.0 with PHP 4.0.4 and IIS 5. Until I upgraded
to Interbase 6.0, I had problems. Here are some snippets that work:
/* Open the Interbase DB */
function db_open($host, $user, $password) {
return ibase_connect($host, $user, $password);
};
/* Is the Session in the Interbase DB? */
function db_is_session($dbh, $sid) {
$stmnt = 'SELECT * FROM SESSIONS WHERE SES_SESSION_ID = ' . $sid;
$sthdl = ibase_query($stmnt,$dbh);
if ($row = ibase_fetch_row($sthdl)) {
$retval = 1;
} else {
$retval = 0;
};
ibase_free_result;
return $retval;
};
Todd
--
Todd Cary
Ariste Software
todd@aristesoftware.com