CREATE SCHEMA IF NOT EXISTS santander DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci ;

\c santander


-----------------------
-- Table `santander`.`tweet`
----------------------

CREATE TABLE IF NOT EXISTS dsa_tweet (  
	id serial NOT NULL,
	data JSONB NULL,
        snap timestamp NULL,
        PRIMARY KEY (id) 
);

CREATE TABLE IF NOT EXISTS dsa_user (  
	id serial NOT NULL,  
	data JSONB NULL,
        snap timestamp NULL,
        PRIMARY KEY (id) 
);

CREATE TABLE IF NOT EXISTS fact (
    idfact serial NOT NULL,
    idtwitter bigint NULL,
    polaridad double precision NULL,
    PRIMARY KEY (idfact) 	 	
);




