以下是AQL查询。
for doc in `managed-function` collect mkey = doc.mkey return mkey
上面的查询只返回唯一的mkey列表,我想返回整张单据,如何实现?
jk9hmnmh1#
您需要将INTO子句添加到COLLECT操作中,例如:
INTO
COLLECT
for doc in `managed-function` collect mkey = doc.mkey into docs = doc return {mkey, docs}
https://www.arangodb.com/docs/stable/aql/operations-collect.html#grouping-syntaxes
1条答案
按热度按时间jk9hmnmh1#
您需要将
INTO
子句添加到COLLECT
操作中,例如:https://www.arangodb.com/docs/stable/aql/operations-collect.html#grouping-syntaxes