Dec 3, 2008 #1 perrymans IS-IT--Management Nov 27, 2001 1,340 US I am setting a string variable and want to check with an IF statement like: If strSQL Like "SELECT" Then But it doesn't work like that, and I am not really sure how to do it right. Thanks. Sean.
I am setting a string variable and want to check with an IF statement like: If strSQL Like "SELECT" Then But it doesn't work like that, and I am not really sure how to do it right. Thanks. Sean.
Dec 3, 2008 #2 MajP Technical User Aug 27, 2005 9,382 US If InStr(strSql, "Select")= 1 Then Upvote 0 Downvote
Dec 3, 2008 #3 MajP Technical User Aug 27, 2005 9,382 US However this also works if strSql Like "Select * Upvote 0 Downvote