1 | INSERT INTO roles (role_name) VALUES
|
---|
2 | ('Admin'),
|
---|
3 | ('User');
|
---|
4 |
|
---|
5 | INSERT INTO users (first_name, last_name, email, password_hash, role_id, last_login_date, register_date) VALUES
|
---|
6 | ('John', 'Doe', 'john.doe@example.com', 'hashedpassword1', 1, '2025-01-01', '2024-12-01'),
|
---|
7 | ('Alice', 'Smith', 'alice.smith@example.com', 'hashedpassword2', 2, '2025-01-02', '2024-12-02'),
|
---|
8 | ('Bob', 'Johnson', 'bob.johnson@example.com', 'hashedpassword3', 2, '2025-01-03', '2024-12-03');
|
---|
9 |
|
---|
10 | INSERT INTO plan (plan_name, max_events, max_notifications, max_predictions) VALUES
|
---|
11 | ('Basic', 100, 50, 10),
|
---|
12 | ('Premium', 1000, 500, 100);
|
---|
13 |
|
---|
14 | INSERT INTO subscription (user_id, plan_id, start_date, end_date, status) VALUES
|
---|
15 | (1, 1, '2025-01-01', '2026-01-01', 'Active'),
|
---|
16 | (2, 2, '2025-01-05', '2026-01-05', 'Active'),
|
---|
17 | (3, 1, '2025-02-01', '2026-02-01', 'Active');
|
---|
18 |
|
---|
19 | INSERT INTO events (sql_date, month_year, year, fraction_date, is_root_event, event_code, goldstein_scale, num_mentions, num_sources, num_articles, avg_tone) VALUES
|
---|
20 | ('2025-02-01', '202502', 2025, 2025.0849, TRUE, '023', 5.5, 120, 50, 30, -2.5),
|
---|
21 | ('2025-03-10', '202503', 2025, 2025.1925, FALSE, '045', 3.2, 200, 90, 60, 1.5),
|
---|
22 | ('2025-04-15', '202504', 2025, 2025.2890, TRUE, '067', 6.8, 300, 120, 80, -3.0);
|
---|
23 |
|
---|
24 | INSERT INTO actors (actor_code, actor_name, country_code, type_code) VALUES
|
---|
25 | ('USA', 'United States', 'US', 'GOV'),
|
---|
26 | ('CHN', 'China', 'CN', 'GOV'),
|
---|
27 | ('RUS', 'Russia', 'RU', 'MIL');
|
---|
28 |
|
---|
29 | INSERT INTO locations (full_name, country_code, adm1_code, latitude, longitude, feature_id) VALUES
|
---|
30 | ('Washington, D.C.', 'US', 'DC', 38.8951, -77.0364, '12345'),
|
---|
31 | ('Beijing', 'CN', 'BJ', 39.9042, 116.4074, '54321'),
|
---|
32 | ('Moscow', 'RU', 'MSK', 55.7558, 37.6173, '67890');
|
---|
33 |
|
---|
34 | INSERT INTO event_details (global_event_id, actor_id, location_id) VALUES
|
---|
35 | (1, 1, 1),
|
---|
36 | (2, 2, 2),
|
---|
37 | (3, 3, 3);
|
---|
38 |
|
---|
39 | INSERT INTO predictions (event_id, actor_id, predicted_date, prediction_type, confidence_score) VALUES
|
---|
40 | (1, 1, '2025-04-01', 'Conflict', 85.5),
|
---|
41 | (2, 2, '2025-05-01', 'Economic Crisis', 78.3),
|
---|
42 | (3, 3, '2025-06-01', 'Military Escalation', 90.2);
|
---|
43 |
|
---|
44 | INSERT INTO conflict_risk (actor1_id, actor2_id, risk_score, predicted_date, description) VALUES
|
---|
45 | (1, 2, 70.2, '2025-06-01', 'High risk of economic sanctions.'),
|
---|
46 | (2, 3, 65.8, '2025-07-10', 'Possible territorial dispute.'),
|
---|
47 | (1, 3, 55.3, '2025-08-15', 'Diplomatic tensions rising.');
|
---|
48 |
|
---|
49 | INSERT INTO notifications (user_id, event_id, notification_date, status) VALUES
|
---|
50 | (1, 1, '2025-02-02', 'Sent'),
|
---|
51 | (2, 2, '2025-03-11', 'Pending'),
|
---|
52 | (3, 3, '2025-04-16', 'Sent');
|
---|
53 |
|
---|
54 | INSERT INTO event_analytics (actor_id, event_id, date, conflict_coefficient, mentions_count, avg_tone, description) VALUES
|
---|
55 | (1, 1, '2025-02-02', 0.75, 100, -1.2, 'Increased tensions in the region.'),
|
---|
56 | (2, 2, '2025-03-11', 0.60, 150, 0.5, 'Positive diplomatic progress.'),
|
---|
57 | (3, 3, '2025-04-16', 0.85, 200, -2.0, 'Escalating rhetoric and military movements.');
|
---|