Forum Discussion
smiller257_1
14 years agoContributor
I think the SQL you would need is:
SELECT DISTINCT Custom1 + '-' + CompanyName as CompanyNumber
FROM Contacts
WHERE ProjId = &ProjId
ORDER BY 1
The ProjId = &ProjId would limit it to the contacts in the current project.
The ORDER BY 1 will sort it by the Custom1 concatinated with the CompanyName.
Hope that helps.