|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2006-09-18 17:54 UTC] tony2001@php.net
[2006-09-18 20:40 UTC] howardt at calhounisd dot org
[2006-09-18 20:45 UTC] phpbugs at thequod dot de
[2006-09-19 13:24 UTC] howardt at calhounisd dot org
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 04 08:00:01 2025 UTC |
Description: ------------ When running an INSERT command through MSSQL_Query, the transaction is successful (the record is inserted) but the script immediately dies ("OR die(...)" is executed). I have followed what documentation I can find on the PHP site, but it dies every time. This does not occur on SELECT or UPDATE commands. Reproduce code: --------------- <? $MSSQL_Link = MSSQL_Connect($DistrictServer, "UserID", "password"); MSSQL_Select_DB($DistrictServerDB, $MSSQL_Link); $Insert_Query = "INSERT INTO table(SchoolID, StateID) VALUES('$StudentNum', '$stateid')"; $Insert_Result = MSSQL_Query($Insert_Query, $MSSQL_Link) OR die("Could not insert record. " . $Insert_Query); echo "Success"; ?> Expected result: ---------------- "Success" should be displayed on the page. Actual result: -------------- "Could not insert record. INSERT INTO table(SchoolID, StateID) VALUES('123456', '987654')" is displayed instead.