| | 1 | |
| | 2 | {{{#!sql |
| | 3 | INSERT INTO "user" (user_name, email, password) VALUES |
| | 4 | ('John Doe', 'john@example.com', 'password123'), |
| | 5 | ('Jane Smith', 'jane@example.com', 'securepass'), |
| | 6 | ('Alice Johnson', 'alice@example.com', 'alicepwd'); |
| | 7 | |
| | 8 | INSERT INTO tag (tag_name) VALUES |
| | 9 | ('Food'), |
| | 10 | ('Work'), |
| | 11 | ('Groceries'), |
| | 12 | ('Entertainment'), |
| | 13 | ('Bills'); |
| | 14 | |
| | 15 | INSERT INTO transaction_account (account_name, balance, user_id) VALUES |
| | 16 | ('Cash', 5000.00, 1), |
| | 17 | ('Bank Account', 20000.00, 1), |
| | 18 | ('Credit Card', -1000.00, 2), |
| | 19 | ('Savings', 15000.00, 2), |
| | 20 | ('Foreign Currency', 300.00, 3); |
| | 21 | |
| | 22 | INSERT INTO transaction (transaction_name, amount, net_amount, date, tag_id) VALUES |
| | 23 | ('Bought groceries', 1000.00, 800.00, '2024-11-23 13:51:35+02:00', 1), |
| | 24 | ('Paid rent', 15000.00, 15000.00, '2024-11-01 17:01:41+02:00', 5), |
| | 25 | ('Dinner with friends', 2500.00, 1500.00, '2024-11-29 22:02:22+02:00', 2), |
| | 26 | ('Movie tickets', 600.00, 600.00, '2024-11-30 17:38:00+02:00', 4), |
| | 27 | ('Electricity bill', 1200.00, 1200.00, '2024-11-02 07:03:35+02:00', 5); |
| | 28 | |
| | 29 | INSERT INTO transaction_breakdown (transaction_id, transaction_account_id, spent_amount, earned_amount) VALUES |
| | 30 | (1, 1, 1000.00, 200.00), -- Spent 1000 on Cash, earned back 200 |
| | 31 | (1, 2, 0.00, 800.00), -- Earned back 800 on Bank Account |
| | 32 | (2, 2, 15000.00, 0.00), -- Spent 15000 on Bank Account for rent |
| | 33 | (3, 1, 2500.00, 1000.00), -- Spent 2500 on Cash, earned back 1000 |
| | 34 | (4, 3, 600.00, 0.00); -- Spent 600 on Credit Card for movie |
| | 35 | }}} |