wiki:RelationlDesign

Version 1 (modified by 221012, 13 days ago) ( diff )

--

Релациско мапирање

Ознаки

Примарните клучеви се означени со bold и underline PK

Надворешните клучеви се означени со FK* за кои во заграда () е напишана табелата која ја референцираат.

Задолжителните атрибути се болдирани.

Табели

  1. User (id, first_name, last_name, email, password_hash, date_of_birth, rating, address_id*(Address), bio)
  1. Property (id, title, description, created_at, owner_id*(User), property_type_id* (Property_Type), address_id *(Address))
  1. Property_Type (id, name)
  1. Property_Image (id, image, property_id*(Property))
  1. Unit (id, unit_number, floor, bedrooms, bathrooms, area_sq_m, rent_amount, property_id* (Property))
  1. Listing (id, available_from, available_to, status, description, unit_id* (Unit))
  1. Lease (id, start_date, end_date, rent_amount, deposit_amount, unit_id * (Unit), tenant_id (Tenant_Profile), landlord_id* (Landlord_Profile))
  1. Payment (id, amount, status, payment_date, payment, lease_id* (Lease), payment_method_id* (Payment_Method))
  1. Payment_Method (id, name)
  1. Tenant_Profile (id*(Profile))
  1. Landlord_Profile (id*(Profile), managed_properties_count, is_agent)
  1. Service_Request (id, decription, request_date, status, lease_id*(Lease), service_category_id * (Service_Category))
  1. Service_Category (id, name)
  1. Maintenance_Log (id, description, maintenance_date, service_request_id * (Service_Request))
  1. Inspection (id, inspection_date, notes, lease_id*(Lease), landlord_id*(Landlord_Profile))
  1. Document (id, file_type, file_url, uploaded_at, user_id * (User), lease_id* (Lease))
  1. Address (id, street, city, number, country)
  1. Message (id, sent_at, content, from_user_id*(User), to_user_id*(User), lease_id*(Lease))

DDL скрипта за бришење на табелите и креирање на табелите

DML скрипта за полнење на табелите со податоци

Историјат

Attachments (3)

Download all attachments as: .zip

Note: See TracWiki for help on using the wiki.