count
The count action is used to count documents:
posts.lunaql
query({
from({
posts: {
where(["user_id", "==", 336898764327514112]);
count!;
};
});
});This will return the total count of documents that belong to a user with the _id "336898764327514112".