Hi Sebastian,
I’m using the search feature in graphql and when I do an integer search or a search like %1, I get an error.
“message”: “OData $search clause not valid: Syntax error: character ‘%’ is not valid at position 0 in ‘%1’.”,
How can I make such search?
Thank you
In general the Search clause is a full text search. I am not sure what you want to achieve, but you will not get results with such a query. It is not a SQL LIKE query.
A fulltext search means that the search string is split into terms and then searched by each term.
Perhaps you are looking for a normal contains search with a filter?
I have a content field (“İçerik”)
and my query:
{searchresult:querySearchContentsWithTotal(search:“100%” orderby:“data/priority/en desc” top:10 skip:0){total items{data{title{en} content{en} description{en} alias{en}}}}}
I want to be able to search for everything in the content.
Yes, because 100% is not a text term. You need a filter.
Thank you Sebastian. I will try that way.
1 Like