I have a simple query where i do 2 inner joins to combine data from 3 tables. within the table i would like to know which table each value comes from. i attempted the following but the syntax is wrong.
select e.subscriberkey, Source CASE WHEN FROM Currently_in_Welcome THEN Source = "E" WHEN FROM Sell_Engage_Unknown THEN Source = "S" WHEN FROM At_Risk_NonEngagement THEN Source = "R" END from Currently_in_Welcome e inner join Sell_Engage_Unknown s on e.subscriberkey = s.subscriberkey inner join At_Risk_NonEngagement r on r.subscriberkey = e.subscriberkey
thanks in advance for all your help.