Skip to content

AM03 — ORDER BY mixes explicit and implicit sort directions

Group: Ambiguity · Auto-fixable: no

Once one ORDER BY term states ASC/DESC, omitting it on the others is ambiguous — readers cannot tell whether the default was intended. State a direction on every term or on none.

bad: ORDER BY a, b DESC
good: ORDER BY a ASC, b DESC

Disable this rule in banshee.toml:

[lint]
exclude = ["AM03"]

Or silence one line with -- noqa: AM03. See Linting.