text: 
  CREATE "insight" createDB WITH PASSWORD 'insight';
  
  CREATE USER insight WITH PASSWORD 'insight';
  
  
  /**
   * pSQL way of "USE insight": change default DB to "insight"
   */
  \c insight
  
  /**
   * Step 1.1 CREATE TABLE for storing Stock Trading Data
   */
  CREATE TABLE REDFIN (
  	SALE_TYPE VARCHAR(50),
  	SOLD_DATE DATE,
  	PROPERTY_TYPE VARCHAR(50),
  	ADDRESS VARCHAR(100) NOT NULL,
  	CITY VARCHAR(50) NOT NULL,
  	STATE VARCHAR(50) NOT NULL,
  	ZIPCODE BIGINT,
  	PRICE BIGINT,
  	BEDS BIGINT,
  	BATHS DOUBLE PRECISION,
  	SQFT BIGINT,
  	LOT_SIZE BIGINT,
  	YEAR_BUILT BIGINT,
  	DAYS_ON_MARKET BIGINT,
  	DOLLAR_PER_SQFT BIGINT,
  	HOA_MONTHLY BIGINT,
  	STATUS VARCHAR(50),
  	URL VARCHAR(100),
  	MLS_NUM VARCHAR(50),
  	LATITUDE DOUBLE PRECISION,
  	LONGITUDE DOUBLE PRECISION,
  	LAST_UPDATE_DATE DATE NOT NULL,
      PRIMARY KEY(ADDRESS, CITY, STATE, ZIPCODE)
  );
  
  /**
   * Step 1.2 provide permission to 'insight' account
   */
  GRANT ALL PRIVILEGES ON TABLE REDFIN to insight;
  
  