Added the following Like filtering pattern:
ssql = ssql + " and Chemicals.[Chemical Name] like '" & txtChemicalName.value & "*' "
The code works as expected. However when I try to make the following modification to append an asterisk to the beginning of the like operator:
ssql = ssgl + " and Chemicals.[Chemical Name] like '*" &
txtChemicalName.value & "*' "
I get the following error; "Error Search Criteria". I can manually enter the command on the Sql Server side without any problems. But can't figure out why appending an asterisk at the beginning to the like operator I get an error on the frontend VBA code. Please Advise?
Thanks,
Clifton.
ssql = ssql + " and Chemicals.[Chemical Name] like '" & txtChemicalName.value & "*' "
The code works as expected. However when I try to make the following modification to append an asterisk to the beginning of the like operator:
ssql = ssgl + " and Chemicals.[Chemical Name] like '*" &
txtChemicalName.value & "*' "
I get the following error; "Error Search Criteria". I can manually enter the command on the Sql Server side without any problems. But can't figure out why appending an asterisk at the beginning to the like operator I get an error on the frontend VBA code. Please Advise?
Thanks,
Clifton.