0

I have the following query

Select alpha_key,name,trading_as ,typeclient from client_details where upper(trading_as) like '%TEST\\''S LOGISTICS SERVICES%' order by name ;

does not return any rows but

Select alpha_key,name,trading_as ,typeclient from client_details where upper(trading_as) = 'TEST\\''S LOGISTICS SERVICES' order by name ;

returns a row.

1 Answer 1

1

You have to escape twice the backslash because there are a double interpretation, one when analizing the string and another one when compare with LIKE.

So your request becomes:

Select alpha_key,name,trading_as ,typeclient 
from client_details 
where upper(trading_as) like '%TEST\\\\''S LOGISTICS SERVICES%' 
order by name ;
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.