Hi
I hope Paul, you can help on this issue.
I am using SQLGridSelectedView to display data from several contacts module. I use the query and parameters as shown below.
In this case I select the data based on those contacts modules ID's.
I can filter the records by the module ID (the DDL works fine) since it is common for both contacts and modules tables but my problem is that if I want to filter the records by the module title it does not work. (the module ID is meaningless to the user)
I think it is because the title is only presented in the modules table.
Any idea how can I do it?
Thanks,
Yehuda
SELECT Modules.ModuleTitle as commity, Contacts.Name AS Name, Contacts.Contact1 AS home Phone, Contacts.Contact2 AS Cell Phone, Contacts.Role AS Work Phone,
'<a href="mailto:' + Contacts.Email + '">Send Email</a>' AS email
FROM Modules INNER JOIN
Contacts ON Contacts.ModuleID = Modules.ModuleID
WHERE ((contacts.ModuleID = 607) or (contacts.ModuleID = 611) or (contacts.ModuleID = 613) or (contacts.ModuleID = 615) or (contacts.ModuleID = 617) or (contacts.ModuleID = 619) or (contacts.ModuleID = 621) or (contacts.ModuleID = 623) or (contacts.ModuleID = 626) or (contacts.ModuleID = 629) or (contacts.ModuleID = 644))
ORDER BY modules.moduletitle
------------------------------------------------------------------------------------------------------------------------------------
The filter by moduleID is:
Parm Name: moduleid
Prompt:
Select: SELECT DISTINCT ModuleID FROM Contacts WHERE ((contacts.ModuleID = 607) OR (contacts.ModuleID = 611) OR (contacts.ModuleID = 613) OR (contacts.ModuleID = 615) OR (contacts.ModuleID = 617) OR (contacts.ModuleID = 619) OR (contacts.ModuleID = 621) OR (contacts.ModuleID = 623) OR (contacts.ModuleID = 626) OR (contacts.ModuleID = 629) OR (contacts.ModuleID = 644))
Clause: Contacts.ModuleID= [Parm:ModuleID]