If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
|
Thread Tools | Display Modes |
#11
|
|||
|
|||
"HAVING LIKE " & """" & "*" 'Active" & "*" & """" & "
I am seeing the Run-time Error 3021
The immediate window displays SELECT downloads.Branch_Number, downloads.msglog_text, downloads.item_id, Min(downloads.msglog_crtdt) AS MinOfmsglog_crtdt FROM downloads GROUP BY downloads.Branch_Number, downloads.msglog_text, downloads.item_id HAVING (((downloads.Branch_Number) = 11) AND ((downloads.msglog_text) Like '*active*') AND ((downloads.item_id) = 1)); If I click debug button it highlights MsgBox (rst2.GetString) |
#12
|
|||
|
|||
"HAVING LIKE " & """" & "*" 'Active" & "*" & """" & "
Oh, comment that out - or if you need it, get rid of the parenthesis -
parens are used when you're passing to a value: msgbox rst2.GetString MyString = msgbox(rst2.GetString) wrote in message oups.com... I am seeing the Run-time Error 3021 The immediate window displays SELECT downloads.Branch_Number, downloads.msglog_text, downloads.item_id, Min(downloads.msglog_crtdt) AS MinOfmsglog_crtdt FROM downloads GROUP BY downloads.Branch_Number, downloads.msglog_text, downloads.item_id HAVING (((downloads.Branch_Number) = 11) AND ((downloads.msglog_text) Like '*active*') AND ((downloads.item_id) = 1)); If I click debug button it highlights MsgBox (rst2.GetString) |
#13
|
|||
|
|||
"HAVING LIKE " & """" & "*" 'Active" & "*" & """" & "
Also - I totally missed this - Doug Steele pointed out that your wildcard
should be a % not a * - ADO doesn't accept the asterisk. "SusanV" wrote in message ... Oh, comment that out - or if you need it, get rid of the parenthesis - parens are used when you're passing to a value: msgbox rst2.GetString MyString = msgbox(rst2.GetString) wrote in message oups.com... I am seeing the Run-time Error 3021 The immediate window displays SELECT downloads.Branch_Number, downloads.msglog_text, downloads.item_id, Min(downloads.msglog_crtdt) AS MinOfmsglog_crtdt FROM downloads GROUP BY downloads.Branch_Number, downloads.msglog_text, downloads.item_id HAVING (((downloads.Branch_Number) = 11) AND ((downloads.msglog_text) Like '*active*') AND ((downloads.item_id) = 1)); If I click debug button it highlights MsgBox (rst2.GetString) |
#14
|
|||
|
|||
"HAVING LIKE " & """" & "*" 'Active" & "*" & """" & "
picky
ADO accepts it. It just doesn't treat it as a wildcard character. g /picky -- Doug Steele, Microsoft Access MVP http://I.Am/DougSteele (no e-mails, please!) "SusanV" wrote in message ... Also - I totally missed this - Doug Steele pointed out that your wildcard should be a % not a * - ADO doesn't accept the asterisk. |
#15
|
|||
|
|||
"HAVING LIKE " & """" & "*" 'Active" & "*" & """" & "
LOL! You most definitely got me there!
"Douglas J Steele" wrote in message ... picky ADO accepts it. It just doesn't treat it as a wildcard character. g /picky -- Doug Steele, Microsoft Access MVP http://I.Am/DougSteele (no e-mails, please!) "SusanV" wrote in message ... Also - I totally missed this - Doug Steele pointed out that your wildcard should be a % not a * - ADO doesn't accept the asterisk. |
#16
|
|||
|
|||
"HAVING LIKE " & """" & "*" 'Active" & "*" & """" & "
Thanks guys! My Boss is going to love this!
|
#17
|
|||
|
|||
"HAVING LIKE " & """" & "*" 'Active" & "*" & """" & "
Glad to help any time!
;-) wrote in message oups.com... Thanks guys! My Boss is going to love this! |
|
Thread Tools | |
Display Modes | |
|
|