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)
 query help

Author  Topic 

dupati1
Posting Yak Master

123 Posts

Posted - 2005-10-26 : 13:20:40
hello All,

I have this table

ClientID | Address | City | State
__________________________________
1 | Default | Blah | WV

2 | Default | Pitt | PA
2 | Pitt, PA | Pitt | PA

3 | Default | Mtow | SC
3 | oak, SC | oak | SC
3 | Blah, WV | Blah | WV

4 | beav, PA | beav | PA

5 | Default | zone | PA
5 | zone, PA | zone | PA
5 | beav, PA | beav | PA


i am in the process of changing the Default address to city+', '+ state format...

ok now i want to find ONLY those records that DO NOT have a Address with City+', '+State description already and having Default as one of their addresses

for example...my query should return clients 1,3

it wont return 2 and 5 because the city and state of the default address is already in the list...

is that clear...

dupati1
Posting Yak Master

123 Posts

Posted - 2005-10-26 : 13:40:59
Please ignore the post...i got it working...
Go to Top of Page
   

- Advertisement -