
--
-- Imports file : populate the database
--


INSERT INTO users (id, username, password, name) VALUES (1, 'jean-renan', '123456',  'chatel');
INSERT INTO users (id, username, password, name) VALUES (2, 'eric', '123456', 'poiseau');
INSERT INTO users (id, username, password, name) VALUES (3, 'anne', '123456', 'dupraz');
SELECT pg_catalog.setval('users_id_seq', 3, true);


INSERT INTO roles(id, name) VALUES (1, 'Admin');
INSERT INTO roles(id, name) VALUES (2, 'Manager');
INSERT INTO roles(id, name) VALUES (3, 'User');
INSERT INTO roles(id, name) VALUES (4, 'Editor');
INSERT INTO roles(id, name) VALUES (5, 'Accounting');
SELECT pg_catalog.setval('roles_id_seq', 5, true);

INSERT INTO user_roles(user_id, role_id) VALUES (3, 3);
INSERT INTO user_roles(user_id, role_id) VALUES (2, 3);
INSERT INTO user_roles(user_id, role_id) VALUES (2, 1);
INSERT INTO user_roles(user_id, role_id) VALUES (2, 2);
INSERT INTO user_roles(user_id, role_id) VALUES (3, 5);
INSERT INTO user_roles(user_id, role_id) VALUES (1, 4);


 
