LIKE filters same as equal sign

Common questions about 1C:Query language, Query builder tool and Data composition schema

#1
People who like this:0Yes/0No
Active user
Rating: 5
Joined: Sep 27, 2011
Company:

Hello!
I have the following problem: I need to filter items in my catalog by a part of Description. I use LIKE clause but it maches entire the string like equal sign does! Here is my query text:

Code
SEL ECT Items.Ref
FR OM Catalog.Items AS Items
WHERE Items.Description LIKE &DescriptionPart

 
#2
People who like this:1Yes/0No
Just came
Rating: 1
Joined: Apr 17, 2012
Company: Zoi TechCon GmbH

Hello.
Try it like that

Code
SetParameter("DescriptionPart","%"+DescriptionPart+"%")

 
#3
People who like this:0Yes/0No
Active user
Rating: 5
Joined: Sep 27, 2011
Company:

Perfect! Thanks!

 
Subscribe
Users browsing this topic (guests: 1, registered: 0, hidden: 0)
Be the first to know tips & tricks on business application development!

A confirmation e-mail has been sent to the e-mail address you provided .

Click the link in the e-mail to confirm and activate the subscription.