PHP 4.0 Bug #6628 Updated: MS-Access: insert statement only exec'd once
| From: | kalowsky@php.net | Date: | Sun, 01 Apr 2001 23:59:32 +0000 |
| Subject: | PHP 4.0 Bug #6628 Updated: MS-Access: insert statement only exec'd once | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-50523@lists.php.net to get a copy of this message | ||
ID: 6628
Updated by: kalowsky
Reported By: bruno.de.winter@advalvas.be
Old-Status: Open
Status: Closed
Bug Type: ODBC related
Assigned To:
Comments:
works fine for me.
Previous Comments:
---------------------------------------------------------------------------
[2000-09-08 10:21:12] bruno.de.winter@advalvas.be
sorry forgot "
----------------------------------------------------------
if ($conws=odbc_pconnect("DB1","Admin","")) {
if ($result=odbc_exec($conws,"insert into MessageQueue (MsgType) values
('MESSAGEONE')") { if (odbc_commit($conws)) {
$result=odbc_exec($conws,"insert into MessageQueue (MsgType) values
('MESSAGETWO')"); odbc_commit($conws); } }
----------------------------------------------------------
---------------------------------------------------------------------------
[2000-09-08 10:18:27] bruno.de.winter@advalvas.be
An insert statement on a MS Access database table only works once in the same script:
----------------------------------------------------------
if ($conws=odbc_pconnect("DB1","Admin","")) {
if ($result=odbc_exec($conws,"insert into MessageQueue (MsgType) values
('MESSAGEONE')) {
if (odbc_commit($conws)) {
$result=odbc_exec($conws,"insert into MessageQueue (MsgType) values
('MESSAGETWO')");
odbc_commit($conws);
}
}
----------------------------------------------------------
MessageQueue is a table with one field: MsgType without an index or constraint.
The second insert is not done, although the 'odbc_commit's are succesfull and
'odbc_exec's do return a handle.
---------------------------------------------------------------------------
ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=6628&edit=2