Created
November 27, 2018 22:37
-
-
Save MarkyC/7fee1af06dfca01b0da1fccbeab55934 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
| -- http://sqlfiddle.com/#!17/9ba87/5 | |
| CREATE TABLE order_event( | |
| id int, | |
| order_id text, | |
| event_name text, | |
| created timestamp default CURRENT_TIMESTAMP | |
| ); | |
| INSERT INTO order_event(id, order_id, event_name) VALUES | |
| (1, 123, 'event A'), | |
| (2, 123, 'event B'), | |
| (3, 123, 'event C'), | |
| (5, 456, 'event A'), | |
| (6, 789, 'event A'), | |
| (7, 789, 'event B'), | |
| (8, 321, 'event A'), | |
| (9, 321, 'event B'), | |
| (11, 321, 'event C'), | |
| (12, 321, 'event D') | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment