Advertisement
valeriygaz

Untitled

Jan 17th, 2025
1,256
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PostgreSQL 1.86 KB | Source Code | 0 0
  1. DO $$
  2. DECLARE
  3.     repair_type_id INT;
  4. BEGIN
  5.     --- creation Repair Type
  6.     INSERT INTO loader_repairtype ("created_at", "updated_at", "name", "short_name")
  7.     VALUES ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'Service provide', '')
  8.     RETURNING id into repair_type_id;
  9.  
  10.     --- creation Measure
  11.     INSERT INTO loader_measure ("created_at", "updated_at", "name", "short_name")
  12.     VALUES ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'Unit', '');
  13.  
  14.     --- creation Sing Code
  15.     INSERT
  16.     INTO loader_signcode ("created_at", "updated_at", "name", "short_name")
  17.     VALUES ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'SV9', 'Additional detail package'),
  18.     ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'ELC4', 'Electrical and electronics work'),
  19.     ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'BRK9', 'Brake system work'),
  20.     ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'AIR7', 'Air conditioning or climate system work'),
  21.     ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'SUS8', 'Suspension and chassis work'),
  22.     ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'BDY3', 'Body repair and restoration'),
  23.     ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'TUN6', 'Tuning and modifications'),
  24.     ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', 'S5', 'Major or extended service package');
  25.  
  26.     --- creation Repair Type Mapping
  27.     INSERT INTO loader_repairtypemapping ("created_at", "updated_at", "values", "instance_id")
  28.     VALUES ('2025-01-11 14:41:09.319000 +00:00', '2025-01-11 14:41:09.319000 +00:00', '{Provision of services (repair works)}', repair_type_id);
  29. END $$;
  30.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement