G
Guest
I have a (simple) question as to how tables relate:
Lets say i have made to tables:
Colors:
Color_id(number) Color(text)
1 White
2 Black
3 Red
and
Cars:
Owner_id(number) Owner(text) Color_id(number)
1 Bob 3
2 Lisa 1
3 John 1
Next i make a report on the table Cars, in wich i group by Color and list
the names, e.i.
1
John
Lisa
3
Bob
Now, instead of showing the Color_id, i want it to display the Color, that is:
White
John
Lisa
Red
Bob
How do i do this? It is important that the information stored in the table
Cars is the Color_id, not just Color.
another way to formulate this (i think) is: Given a secondary key in one
table, how do you refer to a given field in the related table wherein this
key is primary?
Lets say i have made to tables:
Colors:
Color_id(number) Color(text)
1 White
2 Black
3 Red
and
Cars:
Owner_id(number) Owner(text) Color_id(number)
1 Bob 3
2 Lisa 1
3 John 1
Next i make a report on the table Cars, in wich i group by Color and list
the names, e.i.
1
John
Lisa
3
Bob
Now, instead of showing the Color_id, i want it to display the Color, that is:
White
John
Lisa
Red
Bob
How do i do this? It is important that the information stored in the table
Cars is the Color_id, not just Color.
another way to formulate this (i think) is: Given a secondary key in one
table, how do you refer to a given field in the related table wherein this
key is primary?