Sorting fifty thousand rows in the browser

means sending fifty thousand rows.

paginationMode: "local"
GET /Orders/Data
50,000 rows out of one query
6,147,602 bytes
✕ the browser does the ORDER BY
✕ 49,980 rows nobody scrolls to
✕ all of it parsed before row one is drawn
paginationMode: "remote"
GET /Orders/Data?page=1&size=20
ORDER BY "o"."Id"
LIMIT 20 OFFSET 0
2,521 bytes
✓ SQLite does the ORDER BY
✓ 20 rows read, 20 rows sent
✓ the pager's count shares the same WHERE
the sort column is the browser's choice five names in the allowlist, anything else is a 400 Bad Request before the query is built
.NET 10.0.5 · EF Core 10.0.12 · Tabulator 6.5.2 · both byte figures measured by the demo's tests
gdhami.net