summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--task6_triggers.sql18
-rw-r--r--task7_procedures.sql5
2 files changed, 4 insertions, 19 deletions
diff --git a/task6_triggers.sql b/task6_triggers.sql
index 67c79e3..3275880 100644
--- a/task6_triggers.sql
+++ b/task6_triggers.sql
@@ -63,24 +63,6 @@ GO
DELETE FROM Deliveries WHERE driver_id=2
GO
--- Add
-
-INSERT INTO Drivers (city_id, salary, on_delivery)
-VALUES (4, 35000, 0);
-GO
-
-INSERT INTO Vehicles (name, tonnage, gas_consumption)
-VALUES (N'KAMAZ', 30, 50);
-GO
-
-INSERT INTO Routes (city1_id, city2_id, distance)
-VALUES (1, 2, 900);
-GO
-
-INSERT INTO Deliveries (driver_id, vehicle_id, route_id, date)
-VALUES (1, 1, 1, '2021-09-08');
-GO
-
---------------
-- Задание 2 --
---------------
diff --git a/task7_procedures.sql b/task7_procedures.sql
index a93dd3f..891db18 100644
--- a/task7_procedures.sql
+++ b/task7_procedures.sql
@@ -40,8 +40,11 @@ GO
DROP PROCEDURE calculate_order_price
GO
+INSERT INTO Boxes (order_id, warehouse_id, wrapping_id, volume, weight)
+VALUES (100020, 1, 1, 0.1, 10);
+
DECLARE @price INT;
-EXEC calculate_order_price 12, @price OUTPUT;
+EXEC calculate_order_price 100020, @price OUTPUT;
PRINT @price
GO