There are two separate DEs in Marketing Cloud - 'ts2__Placement__c_Salesforce' and 'Contact_Salesforce'. I have created a 3rd DE same using exactly same fields as in 'Contact_Salesforce' and added couple more fields ('Placement_Country__c' and 'candidate_ID__c') which are there in 'ts2__Placement__c_Salesforce'. This 3rd DE has 'Id' as primary key.
Now I am trying to join these two tables into the third one using the following query:
Select
c.Id,
c.SS_Disciplines__c,
c.MailingCountry,
p.Placement_Country__c,
p.candidate_ID__c
From ts2__Placement__c_Salesforce p
JOIN Contact_Salesforce c
ON c.Id = p.candidate_ID__c
(Id is the primary key in 'Contact_Salesforce' but 'candidate_ID__c' is not primary key in 'ts2__Placement__c_Salesforce')
This query is not showing any error but also not fetching any records. Problem is somewhere with the 'join' only as if I run the query on any one of the DE without using 'join', it works.
RIGHT JOIN
instead of justJOIN
? Also, is there more than one record for the samecandidate_ID__c
? If yes, then make sure you’re not using a Primary Key in your target DE