MySQL allows several queries to be entered on a single input line and uses the terminators to distinguish where each query ends. You may use any of several terminators to end a statement. Two terminators are the semicolon character (';') and the \g sequence. They're equivalent and may be used interchangeably.

The \G sequence also terminates queries, but causes mysql to display query results in a vertical style that shows each output row with each column value on a separate line.

The \G terminator is especially useful if a query produces very wide output lines because vertical format can make the result much easier to read. Take an example below.

mysql>  SELECT * FROM user\G

Posted in: MySQL

Related FAQ's

Marius Ion ANGEL HOT SOFT LLC (800) 316-7677