Quantcast
Channel: Optimizely Search & Navigation
Viewing all articles
Browse latest Browse all 6894

filter like string

$
0
0

I have a string array("Sweden","India","Australia"). I want to dispaly those page whose have the follwing anyone country in their tage page.In each page tag data present with coma seprated.

Page1(Hashtag:India,Pakistan,Srilanka)

Page2(Hashtag:Australia,Iran,Nepal)

Page3(Hashtag:Pakistan,Sweden)

Page4(Hashtag:Pakistan,nepal,Srilanka)

Output:

Page,Page2,Page3

Code:

.Instance.Search<ListablePage>()

.For(query)

.Filter(x=> x.Hashtag.In(new Lst<string>{"Sweden","India","Australia"}))

using IN i can not find data from coma separtaed tag. Is there any like searh for it like '%India%' ?


Viewing all articles
Browse latest Browse all 6894

Trending Articles