I'm facing a little problem probably; The scenario is that I have two table A & B.
Table Customer - A (Column)
[Id] ,[Name] ,[Address] ,[Phone] ,[Email]
Table Orders - B (Column)
[Id] ,[CustomerId] ,[Amount]
Here [CustomerId] is a foreign key of table A (Id)
Now, I need to write the sql which will return all the unique customers (no duplicate) that have order. Note that the table B may have multiple order for a single customer.
Don't forget to click [Vote] / [Good Answer] on the post(s) that helped you.
I will not say I have failed 1000 times; I will say that I have discovered 1000 ways that can cause failure - Thomas Edison.
View Complete Post