I would like create a DB concern the buiding.
Tenants hire flats
A building has different flats
There are some buidings
I create 5 tables:
Table_1 : Tenant_ID, Tenant_Name
Table_2 : Building_ID, Buiding_Name
Table_3 : Flat_ID, Flat_number
T_Tenant_Buiding : TE_1_ID, BU_ID
T_Tenant_Flat : TE_2_ID, FL_ID
and 4 Relation****ps :
Tenant_ID = TE_1_ID
Buiding_ID = BU_ID
Tenant_ID = TE_2_ID
Flat_ID = FL_ID
I use ****tal for defining tenant / buiding
and the same, ****tal for defining tenant / flat
the problem that there is no relation between
buiding and flat. And I do not know how to define it!
Can you help me to correct these relation****ps
so in the re****ts I can display :
Buiding_1
Flat_1
Tenant_A
Tenant_B
Tenant_C
Flat_2
....
...
Buiding_2
Flat_1
Tenant_H
Tenant_I
Tenant_J
Flat_2
....
...
Thank you for your help