Last active
February 23, 2017 13:18
-
-
Save jimmy89Li/b79e08456a13b34ff0e0cc844bec49ed to your computer and use it in GitHub Desktop.
Insert sql into multiple tables in the same time
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$sql = "BEGIN TRANSACTION;"; | |
$sql .= "INSERT INTO table1 (name1) VALUES (value1);"; | |
$sql .= "INSERT INTO table2 (name2) VALUES (value2);"; | |
$sql .= "COMMIT;"; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment