like operator doesnt work !

like operator doesnt work !

  

Hi guys

I'm a beginner and I'm trying to filter by using like operator in an aggregate but it doesnt seem to work!
I'm using some thing like this: LocalVar Like "%" + Table.ID "%"

plz help me.

Solution

Hello Sadegh. I think you are inverting the order on the like operator.

Usually you write something like: Table.Name Like "%" + LocalVar + "%"

Note a few key differences. The local variable (which is the search term) is on the right-hand side of the Like operator. You had the variable on the left-hand side. On the left-hand side, you have a text field from the database. You were using the Id which is usually an integer, so that probably needs to be changed.

Solution