cancel
Showing results for 
Search instead for 
Did you mean: 

OData v2 filter - What is happening?

awguthrie
Participant

Greetings,

Hoping somebody can explain what may be happening here. I set up an OData service for a custom structure.

Upon debugging the requests, I don't understand why the filter table is populated in the way that it is.

I'm thinking this is somehow related to the error that I am getting.

The first request example is working as intended.

However, the other string requests result in this error:
This comparison pattern is too long; it must be 256 characters or fewer.

Accepted Solutions (1)

Accepted Solutions (1)

awguthrie
Participant
0 Kudos

I realized what I was doing...

On the UI5 side, the query string is put into the Matkl field and passed to the back end. Since this is the material type (I think going off memory), it's a smaller field so the rest gets chopped.

There's probably a better way to do this, but I just went ahead and changed this to Maktx, which is the material description field and thus has a longer length.

So, taking any of the examples I provided above, the filter now looks like this:
$filter=substringof(%2740000002%27,Maktx)

Now, the whole query string is intact when it hits my program on the back end, and I can use that value as needed.

Answers (0)