I have a SQL 2005 DB with 57,000 accounts and a huge quantity of activities (emails, letters, phone call, etc.) related to the Accounts. I want to find the accounts where there is at least 1 activity...not the number of activities. You can imagine the time it takes to pull this data!
Tbl#1 - Accounts
ID
f1
f2
f3
Tbl#2 - Activities
ID
AccountID
fA
fB
fC
What should my join statement and query look like to get a simple true/false if there is a link?
Tbl#1 - Accounts
ID
f1
f2
f3
Tbl#2 - Activities
ID
AccountID
fA
fB
fC
What should my join statement and query look like to get a simple true/false if there is a link?