-- A small collection of sample users and threads for the forum scenario, provided as part of Workshop 5 of Interactive Web Development
-- "INSERT IGNORE" will skip rows if they cannot be inserted, e.g. in case you already have a user with a username of "bsmith" or "jbloggs"

INSERT IGNORE INTO user (username, password, real_name, dob)

VALUES ('bsmith', 'Password1', 'Bob Smith', '1998-05-21'), 

       ('jbloggs', 'Abc12345', 'Joe Bloggs', '2000-10-01');


INSERT IGNORE INTO thread (username, forum_id, title, content)

VALUES ('bsmith',  1, 'So how about this weather?', 'It has been raining non-stop for the past few days - getting pretty sick of it, plus it\'s really cold!'),

       ('jbloggs', 1, 'Strong rain last night', 'For a few minutes last night, there was a downpour that was stronger than anything I\'ve ever experienced before.\n\nIt was loud enough (on my tin roof) to wake me up and I couldn\'t get back to sleep afterwards!'),
       
       ('jbloggs', 1, 'Turn your lights on when driving in the rain', 'It can be really hard to see other cars on the road, particularly grey ones, when there is heavy rain.\nSo please, turn your lights on!'),
       
       ('bsmith',  2, 'Blazing Swan', 'Anyone ever been to Blazing Swan? It\'s Perth\'s "Burning Man" style event, held up in Kulin. Usually around late March/early April.'),
       
       ('bsmith',  2, 'Perfectly normal thread', 'This not at all a test of whether this forum is vulnerable to XSS attacks.\n<script>alert("Hacked!");</script>\nPlease move along.');