Created
September 13, 2012 14:23
-
-
Save tell-k/3714626 to your computer and use it in GitHub Desktop.
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
INSERT INTO entries (id, text, created_at) VALUES (%s, %s, %s) | |
(1, 'entrytext', datetime.datetime(2012, 9, 13, 23, 21, 11, 165187)) | |
# Session は ここで selectされる事を知ってるから↑で先にInser文をちゃんとDBに流してくれている。 | |
SELECT entries.id AS entries_id, entries.text AS entries_text, entries.created_at AS entries_created_at | |
FROM entries | |
WHERE entries.id = %s | |
LIMIT %s | |
INSERT INTO entries (id, text, created_at) VALUES (%s, %s, %s) | |
(2, 'entrytext', datetime.datetime(2012, 9, 13, 23, 21, 11, 167993)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment