Cannot get .eq to work with Query

This code works ok

  let results = await wixData.query('Stores/Orders')
	  .descending('_dateCreated')
      .limit(100)
      .find(options);
But this does not when I add .eq to filter the results?!
  let results = await wixData.query('Stores/Orders')
	  .eq("currency", "GBP")
	  .descending('_dateCreated')
      .limit(100)
      .find(options);

Error in logs is:

“[“WDE0076: Validation error. {"message":"Unknown token currency → Map($eq → GBP)","details":{}}”]”

I am baffled for many hours... I am sure there is a simple solution ...any ideas ?  I have tried .eq with lots of fields but nothing works when I try and filter the Orders.

[wrong direction - deleted]

J.D. thank you as always but that did not work. Strangely this does work:

  let results = await wixData.query('Stores/Orders')
	.eq("paymentStatus", "PAID")
	  .descending('_dateCreated')
      .limit(100)
      .find(options);

However I do not know how to get .eq to work with a field which contains JSON object e.g. to look up Orders by customer email which is a field within the buyerInfo JSON object. This does not work. Any ideas please?

  let results = await wixData.query('Stores/Orders')
	.eq("buyerInfo.email", email)
	  .descending('_dateCreated')
      .limit(100)
      .find(options);

“[“WDE0076: Validation error. {"message":"Unknown token buyerInfo.email → Map($eq → email)","details":{}}”]”

I suspect that it is only possible to filter queries on certain fields? But this would mean searching the whole collection of orders (may be thousands) to possibly just inspect 2 orders a customer has placed (identified by their unique email) which means slower searching? At the moment i search all orders and then use an if statement on the result items to find the matching email field but that seems a long way? Filtering in the initial query would be faster better?? Thank you in advance.

Hi, since I don’t usually use the Wix Stores app (I use a third party’s transactions/orders), I wouldn’t like to mislead you with my answer.
On first glance the query looks fine to me. Maybe post a sample of your order item.
And maybe someone else will be able to help.

Even though the documentation says that you can filter using contains on plainContent ("Posts" Collection Fields - Velo API Reference - Wix.com…)

I got this error:
Error: WDE0076: Validation error. Unsupported filter operator $contains for plainContent