MySQL  8.0.12
Source Code Documentation
COM_QUERY

Send a Text Protocol based SQL query

Execution starts immediately.

Returns
Payload
TypeNameDescription
int<1> command 0x03: COM_QUERY
string<EOF> query the text of the SQL query to execute
Example
21 00 00 00 03 73 65 6c 65 63 74 20 40 40 76 65 !....select @@ve
72 73 69 6f 6e 5f 63 6f 6d 6d 65 6e 74 20 6c 69 rsion_comment li
6d 69 74 20 31 mit 1
See also
Protocol_classic::parse_packet, dispatch_command, mysql_parse, alloc_query, THD::set_query