MySQL command, without using Manual input

46 Views Asked by At

How to create a table which is included this by MySQL command without using Manual input, see the pic blow:

enter image description here

2

There are 2 best solutions below

0
On BEST ANSWER

You can use this SQL to create a table name as: published

CREATE TABLE published (
  `is_published` BOOLEAN NOT NULL DEFAULT true
) ENGINE=InnoDB;

0
On

Based on the accepted answer, it seems you want the SQL commands that are run by the graphical interface. In the future, you can use phpMyAdmin to show you those queries directly.

When you're on that page to create a new table (or edit an existing table), there's a "Preview SQL" button next to "Save". Clicking that shows the SQL commands that will run, but won't actually run them.

Create table dialog

Preview SQL results