CREATE TABLE formitable_survey (
ID smallint(4) unsigned NOT NULL auto_increment,
first varchar(25) NOT NULL default '',
last varchar(25) NOT NULL default '',
affiliation varchar(70) NOT NULL default '',
city varchar(50) NOT NULL default '',
country varchar(25) NOT NULL default '',
state enum('AK','AL','AR','AZ','CA','CO','CT','DC','DE','FL','GA','HI','IA','ID','IL','IN','KS','KY','LA','MA','MD',
'ME','MI','MN','MO','MS','MT','NA','NC','ND','NE','NH','NJ','NM','NV','NY','OH','OK','OK','OR','PA','RI','SC','SD',
'TN','TX','UT','VA','VT','WA','WI','WV','WY') NOT NULL default 'AK',
email varchar(50) NOT NULL default '',
gender enum('Female','Male') NOT NULL default 'Male',
q1 text NOT NULL,
q2 text NOT NULL,
rate_q1 enum('1','2','3','4','5') NOT NULL default '1',
rate_q2 enum('1','2','3','4','5') NOT NULL default '1',
rate_q3 enum('1','2','3','4','5') NOT NULL default '1',
rate_q4 enum('1','2','3','4','5') NOT NULL default '1',
rate_q5 enum('1','2','3','4','5') NOT NULL default '1',
rate_q6 enum('1','2','3','4','5') NOT NULL default '1',
rate_q7 enum('1','2','3','4','5') NOT NULL default '1',
rate_other tinytext,
statement text NOT NULL,
referral enum('site','flyer','colleague','newsletter','other_ref') NOT NULL default 'site',
referral_other varchar(50) default NULL,
comments text,
PRIMARY KEY (ID)
);
CREATE TABLE states (
Name varchar(40) NOT NULL default '',
Code char(2) NOT NULL default ''
);
INSERT INTO states VALUES (' Select a State', '');
INSERT INTO states VALUES ('Alabama', 'AL');
INSERT INTO states VALUES ('Alaska', 'AK');
INSERT INTO states VALUES ('Arizona', 'AZ');
INSERT INTO states VALUES ('Arkansas', 'AR');
INSERT INTO states VALUES ('California', 'CA');
INSERT INTO states VALUES ('Colorado', 'CO');
INSERT INTO states VALUES ('Connecticut', 'CT');
INSERT INTO states VALUES ('Delaware', 'DE');
INSERT INTO states VALUES ('Florida', 'FL');
INSERT INTO states VALUES ('Georgia', 'GA');
INSERT INTO states VALUES ('Hawaii', 'HI');
INSERT INTO states VALUES ('Idaho', 'ID');
INSERT INTO states VALUES ('Illinois', 'IL');
INSERT INTO states VALUES ('Indiana', 'IN');
INSERT INTO states VALUES ('Iowa', 'IA');
INSERT INTO states VALUES ('Kansas', 'KS');
INSERT INTO states VALUES ('Kentucky', 'KY');
INSERT INTO states VALUES ('Louisiana', 'LA');
INSERT INTO states VALUES ('Maine', 'ME');
INSERT INTO states VALUES ('Maryland', 'MD');
INSERT INTO states VALUES ('Massachusetts', 'MA');
INSERT INTO states VALUES ('Michigan', 'MI');
INSERT INTO states VALUES ('Minnesota', 'MN');
INSERT INTO states VALUES ('Mississippi', 'MS');
INSERT INTO states VALUES ('Missouri', 'MO');
INSERT INTO states VALUES ('Montana', 'MT');
INSERT INTO states VALUES ('Nebraska', 'NE');
INSERT INTO states VALUES ('Nevada', 'NV');
INSERT INTO states VALUES ('New Hampshire', 'NH');
INSERT INTO states VALUES ('New Jersey', 'NJ');
INSERT INTO states VALUES ('New Mexico', 'NM');
INSERT INTO states VALUES ('New York', 'NY');
INSERT INTO states VALUES ('North Carolina', 'NC');
INSERT INTO states VALUES ('North Dakota', 'ND');
INSERT INTO states VALUES ('Ohio', 'OH');
INSERT INTO states VALUES ('Oklahoma', 'OK');
INSERT INTO states VALUES ('Oregon', 'OR');
INSERT INTO states VALUES ('Pennsylvania', 'PA');
INSERT INTO states VALUES ('Puerto Rico', 'PR');
INSERT INTO states VALUES ('Rhode Island', 'RI');
INSERT INTO states VALUES ('South Carolina', 'SC');
INSERT INTO states VALUES ('South Dakota', 'SD');
INSERT INTO states VALUES ('Tennessee', 'TN');
INSERT INTO states VALUES ('Texas', 'TX');
INSERT INTO states VALUES ('Utah', 'UT');
INSERT INTO states VALUES ('Vermont', 'VT');
INSERT INTO states VALUES ('Virgin Islands', 'VI');
INSERT INTO states VALUES ('Virginia', 'VA');
INSERT INTO states VALUES ('Washington', 'WA');
INSERT INTO states VALUES ('West Virginia', 'WV');
INSERT INTO states VALUES ('Wisconsin', 'WI');
INSERT INTO states VALUES ('Wyoming', 'WY');
CREATE TABLE option_names (
ID varchar(25) NOT NULL default '',
name tinytext NOT NULL,
PRIMARY KEY (ID)
);
INSERT INTO option_names VALUES ('other', 'Other (describe below):');
INSERT INTO option_names VALUES ('1', '');
INSERT INTO option_names VALUES ('2', '');
INSERT INTO option_names VALUES ('3', '');
INSERT INTO option_names VALUES ('4', '');
INSERT INTO option_names VALUES ('5', '');
INSERT INTO option_names VALUES ('site', 'SourceForge');
INSERT INTO option_names VALUES ('flyer', 'PHP Classes Site');
INSERT INTO option_names VALUES ('newsletter', 'Article or Email');
INSERT INTO option_names VALUES ('colleague', 'Another Developer');
INSERT INTO option_names VALUES ('other_ref', 'Other (please specify below)');