Hello all! I'm new in this forum! I've been in my new job for a month and half! In my first week, I was assigned to do a database for leasing agreements!
The following are the tables:

- Occupant (OccupantID, Fname, Lname, Center, Nationality, Email, BusinessPhone, MobilePhone, HomePhone, FaxNumber, EmployeeNumber)
- Property (PropertyID, Pname, Paddress, Pcity, Pobox (Foreign Key are: TenantID, LandlordID)
- Reservation (ReservationID, PropertyNumber, NumBed, FurnishingType, PropertyType, Address, MonthlyCharge, LeasedFrom, LeasedTo, (Foreign Keys are: PropertyID and OccupantID)
- Landlord (LandlordID, Landname, LandRepresentative, Phone, Mobile, Email, Pobox)
- Tenant (TenantID, Tname, Taddress, Tphone, TPobox)

Now the relationships are as follow:
- An Occupant has a reservation.
- A property has many reservations.
- A property has one landlord.
- A property has one tenant.
- A property has many occupants.
- A landlord may have one to many properties.
- Tenant can have one to many properties.
I had between the Occupant and Property (a property has many occupants) but deleted it, i thought it wasnt right since the Reservation table is taken a relational between the two.


In the relationship design i did between the tables as follow:
- Occupant and Reservation (one-to-many)
- Property and Reservation (one to many)
- Landlord and Property (one to many)
- Tenant and Property (one to many)

I did everything, and started working on Forms. When doing forms I did Tab control for making it available all in one sheet. The first tab contains Occupants Details.. when starting working on the rest tabs this is what happens:
I insert a new page in the tab form including reservation details, another one also for property, another for landlord, and last one for tenant.

I include them as subform obviously. But there is a problem, i included bottoms for adding new occupant.. when i add a new occupant i include the occupants details, everything goes great, when shifting to the reservation tab and include any info regarding the reservation a pop up windows tells me: "You cannot add or change a record because a related record is required in Table 'Property'"

What is this supposed to mean? Should I include values for property before anything? How can I optimize this problem?

Another thing, regarding the Property, I tried including in all property information on each attibute of the property entity and in the form of this entity i did a drop down list of all properties we deal with. I want that if i enter it as subform in the tab contro of the occupant, when selecting the property name, automatically the rest of the attributes information appears: for example if I select property X, X is included in the property table, I want that automatically when selecting it it gives me values of Property address, property phone... and other attributes.

How can I fix all this problems? It would be great if someone can help me with this, because im feeling so stressed and depressed about it! I want to submit it to my boss and let him know that I can do it :cry:

I will be waiting for your replies! If someone did any similar database for this please inform me!


Thanks,

Suzan