Hi,
I have some tables representing rooms, doors and keys. Each key opens one room.
Some rooms have more than one door. So the depencencies are like this:
key <-1-n-> door <-1-1-> room
There is a view for the keys:
CREATE VIEW v_keys AS SELECT ... FROM keys;
Now I would like to add a column "room" to this view, but without changing the number of rows!
At this point, I would like to assume that all the doors a key may open, belong to the same room. So it would be ok, to just fetch the first room...
How can I add this to the view?
Thanks
Magnus