note 77943 deleted from function.mysql-insert-id by cmb

From: Date: Sun, 16 Feb 2020 13:30:26 +0000
Subject: note 77943 deleted from function.mysql-insert-id by cmb
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-214115@lists.php.net to get a copy of this message
Note Submitter: bonatoque at yahoo.com ---- It seems that, in case of a very first INSERT, mysql_insert_id() returns 0. My guess is that MySQL does not trigger auto increment if the table is empty. Once an entry is present, it works as expected.

« previous php.notes (#214115) next »