I can access documents from an index with one field
query_function = query.Map(
query.Paginate(query.Match(query.Index(index), "fred")),
(recordRef) => query.Get(recordRef)
);
But what if the index requires two parameters fred and true ? How should the query be written then?
ewan
August 26, 2022, 5:01pm
2
The change required is very simple, use an array:
query_function = query.Map(
query.Paginate(query.Match(query.Index(index), ["fred", true])),
(recordRef) => query.Get(recordRef)
);
FQL functions have (mostly) fixed arity, so when you want to pass multiple values, especially to a function that accepts one, you need to use an array.
system
Closed
August 29, 2022, 2:52pm
3
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.