Basic SQL queries

May 24th, 2015

Create a database: CREATE DATABASE places; Create a table with columns specifying the datatype: CREATE TABLE cities ( id int, city varchar(30), state varchar(2), costindex decimal(5,2) ) Insert a new row of data: INSERT INTO cities(id, city, state, costindex) VALUES(1, 'Reno', 'NV', 80.20) Insert data with empty columns: INSERT INTO cities(id, city, state) VALUES(2, 'Provo', […]