[PHP-DEV] Bug #3162: PHP4b3 - mysql_insert_id no longer accepts an arg From: xmtj <email protected>
Date: 01/10/00

From: xmtj <email protected>
Operating system: RH Linux 6.1
PHP version: 3.0.13
PHP Bug Type: MySQL related
Bug description: PHP4b3 - mysql_insert_id no longer accepts an arg

$result = mysql_insert($query)
$id = mysql_insert_id($result)

This worked in PHP3. It fails in php4b3 with an error message:

PHP Warning: Supplied argument is not a valid MySQL-Link resource in /home/httpd/html/yada.php

The solution:

$result = mysql_insert($query)
$id = mysql_insert_id()

Environment:

MySql: 3.22.27
PHP 4.03b

System: Linux rimsweb 2.2.12-20 #1 Mon Sep 27 10:25:54 EDT 1999 i586 unknown

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: php-dev-unsubscribe <email protected>
For additional commands, e-mail: php-dev-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>