Get a list of customers who have bought something and are newsletter suscriptors

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
5 years ago
Hi, maybe someone can help me getting that sql sentence for me, because I don't have Sql knowledge.

Thank you.

Regards.
5 years ago
Im not that good with it eaither
Just use visual editor to play with it
This should work but there maybe better ways

SELECT Customer.Id, Customer.Email AS CustomerEmail, [Order].Id AS OrderId, NewsLetterSubscription.Id AS NewsLetterSubscriptionId
FROM NewsLetterSubscription
INNER JOIN
     Customer ON NewsLetterSubscription.Email = Customer.Email
INNER JOIN
     [Order] ON Customer.Id = [Order].CustomerId
5 years ago
Thank you so much, works perfect, I will delete the duplicates in Excel.

Really appreciated
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.