0

I have to create an attribute group where I have two Data extension, below is the criteria for the same: DE1 field name "Email" DE2 fields name "EamilA" and "EmailP"

i have to create a data relationship between

enter image description here

Issue am not able to join same field(email from DE1) to different fields(emailA and emailP to DE2)

can you please help me find a solution around this attribute group.

Regards, Joey

1
  • Long story short, you cannot connect 1 field from DE#1 to both 2 fields from DE#2 at the same time. And moreover, you cannot create a relationship between the DEs that are connected already. You would need to think of another approach how to achieve your goals that would probably involve DE's architectural adjustments.
    – Niko
    Sep 13 at 13:46
0

I believe the only way you can do this is via SQL.

Something like below should get you there:

SELECT a.email as email,
  a.otherAttributes
FROM [de1] a
WHERE EXISTS (SELECT TOP 1 emailA FROM [de2] b WHERE a.email = b.emailA)
OR EXISTS (SELECT TOP 1 emailP FROM [de2] b WHERE a.email = b.emailP)

You could also do this with left joins instead if you wanted:

SELECT a.email as email,
  a.otherAttributes
FROM [de1] a
LEFT JOIN [de2] b ON a.email = b.emailA
LEFT JOIN [de2] c ON a.email = c.emailP
WHERE b.emailA IS NOT NULL
OR c.emailP IS NOT NULL

In attributes and data relationships or via the UI at all, you cannot do this as honestly, It is not exactly a best practice approach. Utilizing SQL or a Script (not recommended as less efficient) is the only options to do this.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.