Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

getting customers with no orders sql

SELECT DISTINCT I.*, ITO,itemID AS [NULL if never ordered]
FROM Items As I
LEFT JOIN
ItemsInOrder AS ITO
ON I.itemID=ITO.itemID
WHERE ITO,itemID IS NULL
 
PREVIOUS NEXT
Tagged: #customers #orders #sql
ADD COMMENT
Topic
Name
4+2 =