Skip to content

Instantly share code, notes, and snippets.

@alastori
Created April 28, 2014 13:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alastori/11371854 to your computer and use it in GitHub Desktop.
Save alastori/11371854 to your computer and use it in GitHub Desktop.
MySQL - teste simples de criação de database e tabela com colunas auto-increment e varchar
CREATE DATABASE meudb;
SHOW DATABASES;
USE meudb;
CREATE TABLE simples (id INT AUTO_INCREMENT PRIMARY KEY, texto VARCHAR(200));
INSERT INTO simples VALUES (NULL, 'Primeiro teste');
SELECT * from simples;
INSERT INTO simples VALUES (NULL, 'Segundo teste');
SELECT * from simples;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment