This section describes code execution in batch mode.
In batch mode, all the command logic described above is not available, only valid code for the active language can be executed.
When processing SQL code, it is executed statement by statement using the following logic: read/process/print result.
When processing non-SQL code, it is loaded entirely from the input source and executed as a unit.
Use the --interactive (or
-i) command-line option to configure
MySQL Shell to process the input source as if it were being
issued in interactive mode; this enables all the features provided
by the Interactive mode to be used in batch processing.
In this case, whatever the source is, it is read line by line and processed using the interactive pipeline.