Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 Whats the best to do this?

Author  Topic 

jasonmoss
Starting Member

1 Post

Posted - 2007-02-21 : 11:09:41
I have 2 mailing lists in 2 seperate lists in .xls format. I need a mailing list that has the names that aren't on both lists (the names and addresses that appear in either one list or the other).

I have no real sql experience, but it seems that I could import these into a database and pull out a list a lot faster than I could manually pull out names from a sorted and combined spreadsheet.

Does anyone have any ideas where I should start?

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2007-02-21 : 11:58:59
use openquery to open an excel file from sql server.
inport that into a temp table.
do
select * from t1 where not exists (select * from t2 where t1.email = t2.email)

Causing trouble since 1980
blog: http://weblogs.sqlteam.com/mladenp
Go to Top of Page
   

- Advertisement -