|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-10-15 10:13 UTC] jani@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Nov 01 09:00:01 2025 UTC |
Description: ------------ I tired with stored procedures and it did not worked out. here is what i tried: $mysqli = connection1(); $mysqli->autocommit(FALSE); $user = "call insert_user('hello', 'mypass','myemail')"; $mysqli->query($user); printf ("New Record has id %d.\n", $mysqli->insert_id); $mysqli->commit(); exit; Output: New Record has id 0. which is not correct, may be problem is with stored procedures. Reproduce code: --------------- $mysqli = connection1(); $mysqli->autocommit(FALSE); $user = "call insert_user('hello', 'mypass','myemail')"; $mysqli->query($user); printf ("New Record has id %d.\n", $mysqli->insert_id); $mysqli->commit(); exit; Expected result: ---------------- the id number Actual result: -------------- 0