MySQL Basics In Pictures

TIP: Unlike Linux commands, MySQL commands need a semicolon (;) on the end to execute.

If ever you mistakenly end a command string with no semicolon...

CREATE DATABASE us_presidents

...then press ENTER...

...there is no way to "fix" that command.

To continue, just add a semicolon to the new line you are on:

CREATE DATBASE us_presidents
;

If the command is valid, it will execute.

If there was an error in the command string and it's invalid, adding a semicolon here will execute it and MySQL will give an error. Then you can continue from there.