Skip to content

Tag: mysql

Identify connection between two columns and insert corresponding values

I have the following table which you can also find in the SQL fiddle here: I use the following query: All this works fine so far. Event_01 only has a CampaignID. Event_02 and Event_03 have a CampaignID and Products. Now I want that if I select Product B in the query the corresponding values on CampaignID leve…