CreateTable demo

← List all

← Parse another

Parsing "create table sed (\r\n code ..."

Input

Original

create table sed (
  code int not null,
  name varchar(20),
  primary key (code)
)

  

Results

  1. Table structure
  2. Cross-platform SQL
  3. Errata

CreateTable is still young—please comment on any errors or surprises in the Errata section! Thank you.

Table structure

Number of columns: 2

name data_type allow_null default primary_key unique autoincrement charset collate
code INTEGER false true true false
name CHARACTER VARYING(20) true false false false

Cross-platform SQL

MySQL
CREATE TABLE sed ( code INTEGER PRIMARY KEY, `name` CHARACTER VARYING(20) )
PostgreSQL
CREATE TABLE sed ( code INTEGER PRIMARY KEY, "name" CHARACTER VARYING(20) )
Sqlite3
CREATE TABLE sed ( code INTEGER PRIMARY KEY, "name" CHARACTER VARYING(20) )

Errata

comments powered by Disqus

© 2017 Brighter Planet, Inc.