|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Ok, I'm still lost with JOINs. I have several sub-tables which I want to comglomerate with my main table. For example, let's say I have a table like this:
ID Widget1 Widget2 ------------------ 1 1 2 2 3 4 and another table like this: ID Description -------------- 1 Widget1 2 Widget2 3 Widget3 4 Widget4 I want to be able to end up with a table like this: ID Widget1 Widget2 ------------------ 1 Widget1 Widget2 2 Widget3 Widget4 I can get a one column version of this working by doing something like this: SELECT tblWidgets.DESCRIPTION FROM tblItems LEFT JOIN tblWidgets ON tblItems.Widget1=tblWidgets.ID but I can't get it to work for two or more items. Do I need to use 2 seperate select statements? I have tables where I have 4 or 5 of these situations...it seems like one statement would be very cumbersome. dazed and confused. :-) Thanks! |
![]() |
| Viewing: Dev Shed Forums > Databases > MySQL Help > Need Help with JOIN |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|