Hi all,
I wonder if anyone can help with this sql:
Table "Property_Name" catalogs properties: (property_id,
property_name)
Table "File_Property" catalogs files and their properties: (file_id,
property_id, property_value)
Data example:
Property_Name contains:
Property_ID Property_Name
---------------------------
1 Property_1
2 Property_2
3 Property_3
File_Property contains:
File_ID Property_ID Property_Value
----------------------------------------
111 1 AAA
111 2 BBB
111 3 CCC
222 1 XXX
222 3 ZZZ
333 2 GGG
I want get a list of ALL THE POSSIBLE PROPERTIES and show the values
where there are any:
111 1 Property_1 AAA
111 2 Property_2 BBB
111 3 Property_3 CCC
222 1 Property_1 XXX
222 2 Property_2 <null>
222 3 Property_3 ZZZ
333 1 Property_1 <NULL>
333 2 Property_2 GGG
333 3 Property_3 <null>
I tried all flavors of JOIN but none lists all the possible
properties. Can you help?
Thanks in advance,