LyndonOHRC
Programmer
Please see
[link ]Thread Incorrectly Created in SQL Forum[/url] for start of thread.
Still getting syntax error in query
Lyndon
[link ]Thread Incorrectly Created in SQL Forum[/url] for start of thread.
Still getting syntax error in query
Code:
Select License.*, Applications.ApplicationYear
From License, Applications
Where License.ID=Applications.MasterID
And License.Status='PENDING'
And Applications.ApplicationYear >= '2018'
And License.id IN
(
SELECT TOP 50 License.id
FROM License L JOIN Applications A on L.ID = A.MasterID
WHERE L.AssignedAgent = License.AssignedAgent
Order By A.ApplicationYear, L.LastName, L.FirstName
)
Order By License.AssignedAgent, Applications.ApplicationYear, License.LastName, License.FirstName
Lyndon