[svn r12116] add missing survey field

skala
Patrick Cool 18 years ago
parent e77e20da88
commit 04a9938157
  1. 1
      main/inc/lib/add_course.lib.inc.php
  2. 2
      main/install/migrate-db-1.6.x-1.8.0-pre.sql

@ -1252,6 +1252,7 @@ function update_Db_course($courseDbName)
invitation_code varchar(250) NOT NULL,
invitation_date datetime NOT NULL,
reminder_date datetime NOT NULL,
answered int(2) NOT NULL default '0',
PRIMARY KEY (survey_invitation_id)
)";
$result = mysql_query($sql) or die(mysql_error($sql));

@ -168,7 +168,7 @@ ALTER TABLE user_course_category ADD `sort` int;
-- xxCOURSExx
-- trying to keep the same order in tables declaration as in add_course.lib.inc.php
CREATE TABLE survey ( survey_id int unsigned NOT NULL auto_increment, code varchar(20) default NULL, title text default NULL, subtitle text default NULL, author varchar(20) default NULL, lang varchar(20) default NULL, avail_from date default NULL, avail_till date default NULL, is_shared char(1) default '1', template varchar(20) default NULL, intro text, surveythanks text, creation_date datetime NOT NULL default '0000-00-00 00:00:00', invited int NOT NULL, answered int NOT NULL, invite_mail text NOT NULL, reminder_mail text NOT NULL, PRIMARY KEY (survey_id));
CREATE TABLE survey_invitation (survey_invitation_id int unsigned NOT NULL auto_increment, survey_code varchar(20) NOT NULL, user varchar(250) NOT NULL, invitation_code varchar(250) NOT NULL, invitation_date datetime NOT NULL, reminder_date datetime NOT NULL, PRIMARY KEY (survey_invitation_id));
CREATE TABLE survey_invitation (survey_invitation_id int unsigned NOT NULL auto_increment, survey_code varchar(20) NOT NULL, user varchar(250) NOT NULL, invitation_code varchar(250) NOT NULL, invitation_date datetime NOT NULL, reminder_date datetime NOT NULL, answered int(2) NOT NULL default '0', PRIMARY KEY (survey_invitation_id));
CREATE TABLE survey_question ( question_id int unsigned NOT NULL auto_increment, survey_id int unsigned NOT NULL, survey_question text NOT NULL, survey_question_comment text NOT NULL, type varchar(250) NOT NULL, display varchar(10) NOT NULL, sort int NOT NULL, shared_question_id int, max_value int, PRIMARY KEY (question_id) );
CREATE TABLE survey_question_option ( question_option_id int unsigned NOT NULL auto_increment, question_id int unsigned NOT NULL, survey_id int unsigned NOT NULL, option_text text NOT NULL, sort int NOT NULL, PRIMARY KEY (question_option_id) );
CREATE TABLE survey_anwser (answer_id unsigned int NOT NULL auto_increment, survey_id int unsigned NOT NULL, question_id int NOT NULL, option_id int NOT NULL, value int unsigned not null, user varchar(250) NOT NULL, PRIMARY KEY (answer_id) );

Loading…
Cancel
Save