cancel
Showing results for 
Search instead for 
Did you mean: 

Query with Like

Former Member
0 Kudos

Hello,

I want to create a query to find all articles that start with a certain string.

I have tried this:

SELECT T0.ItemCode FROM OITM T0 WHERE T0.ItemCode LIKE '_%' + LTRIM(RTRIM('[%0]')) + '%'

but this doesn't do the job.

rgds,

John

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

sorry if you want articles that start with a defined string is

SELECT T0.ItemCode FROM OITM T0 WHERE T0.Itemcode LIKE '[%0]%'

Answers (2)

Answers (2)

Former Member
0 Kudos

Thanks

Former Member
0 Kudos

Try

SELECT T0.ItemCode FROM OITM T0 WHERE T0.Itemcode LIKE '%[%0]'