I having attempting to get my query to get criteria input from a Public Function in order to create the output for a report. In the Public Function I have it set up like this:
Option Compare Database
Option Explicit
Dim strDom As String
Public Function FindDomain()
FindDomain = strDom
End Function
So what I have done is try to gather the data from FindDomain() and have the quey on look for that data. Something like this:
SELECT [CERT June].Category, Status.Weight, Status.Status, Sum([CERT June].Count) AS SumOfCount, [CERT June].Domain
FROM [CERT June] RIGHT JOIN Status ON [CERT June].Status = Status.Status
GROUP BY [CERT June].Category, Status.Weight, Status.Status, [CERT June].Domain
HAVING ((([CERT June].Domain)=FindDomain()))
ORDER BY [CERT June].Category, Status.Weight;
What am I doing wrong, Please help....
Option Compare Database
Option Explicit
Dim strDom As String
Public Function FindDomain()
FindDomain = strDom
End Function
So what I have done is try to gather the data from FindDomain() and have the quey on look for that data. Something like this:
SELECT [CERT June].Category, Status.Weight, Status.Status, Sum([CERT June].Count) AS SumOfCount, [CERT June].Domain
FROM [CERT June] RIGHT JOIN Status ON [CERT June].Status = Status.Status
GROUP BY [CERT June].Category, Status.Weight, Status.Status, [CERT June].Domain
HAVING ((([CERT June].Domain)=FindDomain()))
ORDER BY [CERT June].Category, Status.Weight;
What am I doing wrong, Please help....