== Релациска шема (со мапирачка трансформација) === Ознаки * Примарните клучеви се означени со bold и underline * Надворешните клучеви се означени со * * Задолжителни атрибути, односно not null со bold === Табели * Address (**__AddressId__**, **Street**, **City**, **!PostCode**, **!PhoneNumber**, **!StreetNumber**) * !WineType (**__WineTypeId__**, **!WineTypeName**, **!WineTypeDescription**, **!WineTypeRegion**) * Wine (**__WineId__**, **!WineTypeID***(!WineType), **!WineName**, **!BasePrice**, **!YearProduced**) * !CustomerType (**__CustomerTypeId__**, **!CustomerTypeName**, **!CustomerTypeDescription**) * Customer (**__CustomerId__**, **!CustomerTypeId***(!CustomerType), **!AddressId***(Address), **!CustomerName**, **!CustomerEmail**) * !VehicleType (**__VehicleTypeId__**, **!VehicleTypeName**) * Vehicle (**__VehicleId__**, **!VehicleTypeId***(!VehicleType), **Make**, **Model**, **Registration**, **Capacity**) * !ExpenseType (**__ExpenseTypeId__**, **!ExpenseTypeName**, **!ExpenseTypeDescription**) * Employee (**__EmployeeId__**, **!EmployeeName**, **!EmployeeSurname**) * Warehouse (**__WarehouseId__**, **!AddressId***(Address), **!WarehouseName**) * Shipment (**__ShipmentId__**, **!EmployeeId***(Employee), **!PaymentId***(Payment), **!VehicleId***(Vehicle), **!ShipmentDate**) * Payment (**__PaymentId__**, **!PaymentStatus**) * Load (**__LoadId__**, **!ShipmentId***(Shipment),**!CustomerId***(Customer), **!WineId***(Wine), **Quantity**, **!BasePrice**, **!AgreedPrice**) === DDL скрипта за бришење на табелите и креирање на табелите [[File(V1_Init_DB.sql)]] === DML скрипта за полнење на табелите со податоци во тек... === Релациски дијаграм изваден од DBeaver [[Image(ERDiagram DBeaver.png)]]