Reads and writes · rule
query.aggregate_argument
Aggregate is given the wrong arguments.
Area 6, Reads and writes; not declinable; the next step is usually the agent's.
type LeafCount = Int { min: 1}entity Book { id: Uuid leaves: LeafCount}type ShelfLength = Output { mean_leaves: Decimal?}query shelf_length() -> ShelfLength { from: Book aggregate: { mean_leaves: average(Book.leaves) }}
error: `average` needs `scale:` and `rounding:` --> main.jadpo:17:22 |17 | mean_leaves: average(Book.leaves) | ^^^^^^^^^^^^^^^^^^^^ wrong arguments reason: An average rarely comes out exact, so it says how many places it keeps and how the last one is rounded, both written out: `average(Book.<field>, scale: 2, rounding: Rounding.half_even)`. next: Add `scale:` and `rounding:` (agent) rule: query.aggregate_argument help: https://jadpo.dev/docs/errors/query.aggregate_argumentcheck failed: 1 error, 1 file
Markdown for agents: /docs/errors/query.aggregate_argument.md.Built from Jadpo main at a707efb.