For manual fixes in a database, I like having a record of what was typed and what came back. The client has that built in.
MariaDB [shop]> tee /tmp/fix-orders.log
MariaDB [shop]> SELECT count(*) FROM orders WHERE total = 0;
MariaDB [shop]> notee
Between tee and notee, the client appends everything to the file: the prompt with each query, the result tables and the row counts. You still see it all on screen as well. The short form is \T /tmp/fix-orders.log, and you can start with it on from the shell using mariadb --tee=/tmp/fix-orders.log shop.
That file is useful afterwards. You can paste it into a ticket, compare the counts before and after, or work out what went wrong when a fix did more than planned.
Keep in mind where the file lands. The path is on the machine where the client runs, so inside a container it ends up in the container’s filesystem and disappears with it. The log also contains the data you queried, so do not leave it in /tmp on a shared server. The client appends to an existing file and never empties it, so one file can collect several sessions.
Further reading: mariadb command-line client