E
egun
This VBA snippet works and returns a single record (because there is only one
"1150" in the table):
sqltext = "SELECT tlkpWBS.ID FROM tlkpWBS WHERE tlkpWBS.WBS Like ""1150""; "
Set con2 = CurrentProject.Connection
Set rs = New ADODB.Recordset
rs.Open sqltext, con2, adOpenStatic, adLockReadOnly, adCmdText
If I change the 1150 to 115* as below, I get zero records returned. Can
someone tell me why? It works okay in a query with exactly the same SQL
string.
sqltext = "SELECT tlkpWBS.ID FROM tlkpWBS WHERE tlkpWBS.WBS Like ""115*""; "
Thanks,
Eric
"1150" in the table):
sqltext = "SELECT tlkpWBS.ID FROM tlkpWBS WHERE tlkpWBS.WBS Like ""1150""; "
Set con2 = CurrentProject.Connection
Set rs = New ADODB.Recordset
rs.Open sqltext, con2, adOpenStatic, adLockReadOnly, adCmdText
If I change the 1150 to 115* as below, I get zero records returned. Can
someone tell me why? It works okay in a query with exactly the same SQL
string.
sqltext = "SELECT tlkpWBS.ID FROM tlkpWBS WHERE tlkpWBS.WBS Like ""115*""; "
Thanks,
Eric