Hellos,
I'm trying to write a query to get results from 2 tables.
Sites
Idx SiteCode SiteLoc
1 SiteA Town1
2 SiteB Town2
3 SiteC Town3
4 SiteD Town4
and
Rights
Idx SiteCode UserID
1 SiteC User4
2 SiteA User2
3 SiteD User2
The return I need has 2 parts.
1. The list contains all sites in Asc order
2. In the Asc order sites where the user has rights are notated.
IE.
SiteA Town1 User2
SiteB Town2
SiteC Town3
SiteD Town4 User2
I've tried a few different join types to get the results. The best I've been able to get is a sorted listing of the sites the user has rights in.
IE.
SiteA Town1 User2
SiteD Town4 User2
Any help would be appreciated
Thanks, Danzig
I'm trying to write a query to get results from 2 tables.
Sites
Idx SiteCode SiteLoc
1 SiteA Town1
2 SiteB Town2
3 SiteC Town3
4 SiteD Town4
and
Rights
Idx SiteCode UserID
1 SiteC User4
2 SiteA User2
3 SiteD User2
The return I need has 2 parts.
1. The list contains all sites in Asc order
2. In the Asc order sites where the user has rights are notated.
IE.
SiteA Town1 User2
SiteB Town2
SiteC Town3
SiteD Town4 User2
I've tried a few different join types to get the results. The best I've been able to get is a sorted listing of the sites the user has rights in.
IE.
SiteA Town1 User2
SiteD Town4 User2
Any help would be appreciated
Thanks, Danzig