Ernest Grogg
asked on
View SQL Count Records
Hello,
How can I view the count from the code below?
?? msgbox "My Count is " & mycount
How can I view the count from the code below?
?? msgbox "My Count is " & mycount
Dim mycount As String
mycount = "SELECT Count(*) AS MyCount " & vbCrLf & _
"FROM BackgroundCheck " & vbCrLf & _
"WHERE (((BackgroundCheck.Background) Not Like ""Access Denied"" And (BackgroundCheck.Background)=""Waiver Denied"" And (BackgroundCheck.Background)=""Waiver Granted"") AND ((BackgroundCheck.DateNeededCheck)<DateAdd(""yyyy"",-1,Date()-1)));"
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks,
I had to change ste5an's just a bit to get it to work: (the condition had a syntax error, so I removed and changed the fields to 0)
I also had the string slightly wrong, so this below I had to have it looking just for the 1 .
AND
Rey Obrero (Capricorn1) was good to go also...granting both as great solutions.
Open in new window