mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 05:58:34 +01:00
Deleting some old oci8po files from CVS.
This commit is contained in:
parent
8914508a4b
commit
b4c7bb78fc
@ -1,130 +0,0 @@
|
||||
rem
|
||||
rem Table structure for table prefix_backup_files
|
||||
rem
|
||||
|
||||
drop table prefix_backup_files;
|
||||
|
||||
CREATE TABLE prefix_backup_files (
|
||||
backup_code number(10) default '0' NOT NULL,
|
||||
file_type varchar2(10) default '' NOT NULL,
|
||||
path varchar2(255) default '' NOT NULL,
|
||||
old_id number(10) default NULL,
|
||||
new_id number(10) default NULL
|
||||
);
|
||||
|
||||
ALTER TABLE prefix_backup_files
|
||||
ADD CONSTRAINT pbf_pk
|
||||
PRIMARY KEY (backup_code,file_type,path);
|
||||
|
||||
COMMENT on table prefix_backup_files is 'To store and recode ids to user and course files.';
|
||||
|
||||
rem --------------------------------------------------------
|
||||
rem
|
||||
rem Table structure for table prefix_backup_ids
|
||||
rem
|
||||
|
||||
drop table prefix_backup_ids;
|
||||
|
||||
CREATE TABLE prefix_backup_ids (
|
||||
backup_code number(12) default '0' NOT NULL,
|
||||
table_name varchar2(30) default '' NOT NULL,
|
||||
old_id number(10) default '0' NOT NULL,
|
||||
new_id number(10) default NULL,
|
||||
info varchar2(20)
|
||||
);
|
||||
|
||||
ALTER TABLE prefix_backup_ids
|
||||
ADD CONSTRAINT pbi_pk
|
||||
PRIMARY KEY (backup_code,table_name,old_id);
|
||||
|
||||
COMMENT on table prefix_backup_ids is 'To store and convert ids in backup/restore';
|
||||
|
||||
rem --------------------------------------------------------
|
||||
rem
|
||||
rem Table structure for table prefix_backup_config
|
||||
rem
|
||||
|
||||
drop TABLE prefix_backup_config;
|
||||
|
||||
CREATE TABLE prefix_backup_config (
|
||||
id number(10) default '0' not null,
|
||||
name varchar2(255) default '' not null,
|
||||
value varchar2(255) default '' not null,
|
||||
constraint pk_baco primary key (id),
|
||||
constraint uk_baco_name unique (name)
|
||||
);
|
||||
|
||||
COMMENT on table prefix_backup_config is 'To store backup configuration variables';
|
||||
|
||||
drop sequence p_backup_config_seq;
|
||||
create sequence p_backup_config_seq;
|
||||
|
||||
create or replace trigger p_backup_config_trig
|
||||
before insert on prefix_backup_config
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_backup_config_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
rem
|
||||
rem Table structure for table prefix_backup_courses
|
||||
rem
|
||||
|
||||
drop TABLE prefix_backup_courses;
|
||||
|
||||
CREATE TABLE prefix_backup_courses (
|
||||
id number(10) default '0' NOT NULL,
|
||||
courseid number(10) default '0' NOT NULL,
|
||||
laststarttime number(10) default '0' NOT NULL,
|
||||
lastendtime number(10) default '0' NOT NULL,
|
||||
laststatus varchar2(1) default '0' NOT NULL,
|
||||
nextstarttime number(10) default '0' NOT NULL,
|
||||
constraint pk_bacu primary key (id),
|
||||
constraint uk_bacu_courseid unique (courseid)
|
||||
);
|
||||
|
||||
COMMENT on table prefix_backup_courses is 'To store every course backup status';
|
||||
|
||||
drop sequence p_backup_courses_seq;
|
||||
create sequence p_backup_courses_seq;
|
||||
|
||||
create or replace trigger p_backup_courses_trig
|
||||
before insert on prefix_backup_courses
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_backup_courses_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
rem
|
||||
rem Table structure for table prefix_backup_log
|
||||
rem
|
||||
|
||||
drop TABLE prefix_backup_log;
|
||||
|
||||
CREATE TABLE prefix_backup_log (
|
||||
id number(10) default '0' NOT NULL,
|
||||
courseid number(10) default '0' NOT NULL,
|
||||
time number(10) default '0' NOT NULL,
|
||||
laststarttime number(10) default '0' NOT NULL,
|
||||
info varchar2(255) default '0' NOT NULL,
|
||||
constraint pk_balo primary key (id)
|
||||
);
|
||||
|
||||
COMMENT on table prefix_backup_log is 'To store every course backup log info';
|
||||
|
||||
drop sequence p_backup_log_seq;
|
||||
create sequence p_backup_log_seq;
|
||||
|
||||
create or replace trigger p_backup_log_trig
|
||||
before insert on prefix_backup_log
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_backup_log_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
|
||||
/
|
@ -1,13 +0,0 @@
|
||||
<?php
|
||||
|
||||
function chat_upgrade($oldversion) {
|
||||
// This function does anything necessary to upgrade
|
||||
// older versions to match current functionality
|
||||
|
||||
global $CFG;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
|
@ -1,133 +0,0 @@
|
||||
rem
|
||||
rem Table structure for table chat
|
||||
rem
|
||||
|
||||
drop TABLE prefix_chat;
|
||||
CREATE TABLE prefix_chat (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' not null,
|
||||
name varchar2(255) default '' not null,
|
||||
intro varchar2(1024) NOT NULL,
|
||||
keepdays number(11) default '0' not null,
|
||||
studentlogs number(4) default '0' not null,
|
||||
chattime number(10) default '0' not null,
|
||||
schedule number(4) default '0' not null,
|
||||
timemodified number(10) default '0' not null
|
||||
);
|
||||
|
||||
|
||||
COMMENT on table prefix_chat is 'Each of these is a chat room';
|
||||
|
||||
drop sequence p_chat_seq;
|
||||
create sequence p_chat_seq;
|
||||
|
||||
create or replace trigger p_chat_trig
|
||||
before insert on prefix_chat
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_chat_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_chat(course,name,intro,keepdays,studentlogs,chattime,schedule,timemodified) values(1,'name 1','intro 1',1,1,1,1,1);
|
||||
insert into prefix_chat(course,name,intro,keepdays,studentlogs,chattime,schedule,timemodified) values(2,'name 2','intro 2',2,2,2,2,2);
|
||||
insert into prefix_chat(course,name,intro,keepdays,studentlogs,chattime,schedule,timemodified) values(3,'name 3','intro 3',3,3,3,3,3);
|
||||
insert into prefix_chat(course,name,intro,keepdays,studentlogs,chattime,schedule,timemodified) values(4,'name 4','intro 4',4,4,4,4,4);
|
||||
|
||||
select * from prefix_chat;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
rem
|
||||
rem Table structure for table chat_messages
|
||||
rem
|
||||
|
||||
drop TABLE prefix_chat_messages;
|
||||
CREATE TABLE prefix_chat_messages (
|
||||
id number(10) primary key,
|
||||
chatid number(10) default '0' not null,
|
||||
userid number(10) default '0' not null,
|
||||
system number(1) default '0' not null,
|
||||
message varchar2(1024) NOT NULL,
|
||||
timestamp number(10) default '0' not null
|
||||
);
|
||||
|
||||
COMMENT on table prefix_chat_messages is 'Stores all the actual chat messages';
|
||||
|
||||
create index timemodifiedchat on prefix_chat_messages(timestamp,chatid);
|
||||
|
||||
drop sequence p_chat_messages_seq;
|
||||
create sequence p_chat_messages_seq;
|
||||
|
||||
create or replace trigger p_chat_messages_trig
|
||||
before insert on prefix_chat_messages
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_chat_messages_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_chat_messages (chatid,userid,system,message,timestamp) values(1,1,1,'message1',1);
|
||||
insert into prefix_chat_messages (chatid,userid,system,message,timestamp) values(2,2,2,'message2',2);
|
||||
insert into prefix_chat_messages (chatid,userid,system,message,timestamp) values(3,3,3,'message3',3);
|
||||
insert into prefix_chat_messages (chatid,userid,system,message,timestamp) values(4,4,4,'message4',4);
|
||||
|
||||
select * from prefix_chat_messages;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table chat_users
|
||||
rem
|
||||
|
||||
drop TABLE prefix_chat_users;
|
||||
CREATE TABLE prefix_chat_users (
|
||||
id number(10) primary key,
|
||||
chatid number(11) default '0' not null,
|
||||
userid number(11) default '0' not null,
|
||||
version varchar2(16) default '' not null,
|
||||
ip varchar2(15) default '' not null,
|
||||
firstping number(10) default '0' not null,
|
||||
lastping number(10) default '0' not null,
|
||||
lastmessageping number(10) default '0' not null,
|
||||
sid varchar2(32) default '' not null,
|
||||
course number(10) default '0' not null,
|
||||
lang varchar2(10) default '' not null
|
||||
);
|
||||
|
||||
create index userid on prefix_chat_users(userid);
|
||||
create index lastping on prefix_chat_users(lastping);
|
||||
|
||||
drop sequence p_chat_users_seq;
|
||||
create sequence p_chat_users_seq;
|
||||
|
||||
create or replace trigger p_chat_users_trig
|
||||
before insert on prefix_chat_users
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_chat_users_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
COMMENT on table prefix_chat_users is 'Keeps track of which users are in which chat rooms';
|
||||
|
||||
insert into prefix_chat_users (chatid,userid,version,ip,firstping,lastping,lastmessageping,sid) values(1,1,'version1','ip1',1,1,1,'sid1');
|
||||
insert into prefix_chat_users (chatid,userid,version,ip,firstping,lastping,lastmessageping,sid) values(2,2,'version2','ip2',2,2,2,'sid2');
|
||||
insert into prefix_chat_users (chatid,userid,version,ip,firstping,lastping,lastmessageping,sid) values(3,3,'version3','ip3',3,3,3,'sid3');
|
||||
insert into prefix_chat_users (chatid,userid,version,ip,firstping,lastping,lastmessageping,sid) values(4,4,'version4','ip4',4,4,4,'sid4');
|
||||
|
||||
select * from prefix_chat_users;
|
||||
|
||||
delete from prefix_log_display where module='chat';
|
||||
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('chat', 'view', 'chat', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('chat', 'add', 'chat', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('chat', 'update', 'chat', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('chat', 'report', 'chat', 'name');
|
||||
|
||||
select * from prefix_log_display where module='chat' order by 1,2,3,4;
|
@ -1,10 +0,0 @@
|
||||
<?php
|
||||
|
||||
function choice_upgrade($oldversion) {
|
||||
// This function does anything necessary to upgrade
|
||||
// older versions to match current functionality
|
||||
|
||||
return true;
|
||||
}
|
||||
?>
|
||||
|
@ -1,93 +0,0 @@
|
||||
rem
|
||||
rem Table structure for table choice
|
||||
rem
|
||||
|
||||
drop TABLE prefix_choice;
|
||||
CREATE TABLE prefix_choice (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' not null,
|
||||
name varchar2(255) default '' not null,
|
||||
text varchar2(1024) NOT NULL,
|
||||
format number(2) default '0' not null,
|
||||
answer1 varchar2(255) default 'Yes' not null,
|
||||
answer2 varchar2(255) default 'No' not null,
|
||||
answer3 varchar2(255) default NULL,
|
||||
answer4 varchar2(255) default NULL,
|
||||
answer5 varchar2(255) default NULL,
|
||||
answer6 varchar2(255) default NULL,
|
||||
publish number(2) default '0' not null,
|
||||
timemodified number(10) default '0' not null
|
||||
);
|
||||
|
||||
COMMENT on table prefix_choice is 'Available choices are stored here.';
|
||||
|
||||
drop sequence p_choice_seq;
|
||||
create sequence p_choice_seq;
|
||||
|
||||
create or replace trigger p_choice_trig
|
||||
before insert on prefix_choice
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_choice_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_choice(course,name,text,format,answer1,answer2,answer3,answer4,answer5,answer6,publish,timemodified) values(1,'name1','text1',1,'1','1','1','1','1','1',1,1);
|
||||
insert into prefix_choice(course,name,text,format,answer1,answer2,answer3,answer4,answer5,answer6,publish,timemodified) values(2,'name2','text2',2,'2','2','2','2','2','2',2,2);
|
||||
insert into prefix_choice(course,name,text,format,answer1,answer2,answer3,answer4,answer5,answer6,publish,timemodified) values(3,'name3','text3',3,'3','3','3','3','3','3',3,3);
|
||||
insert into prefix_choice(course,name,text,format,answer1,answer2,answer3,answer4,answer5,answer6,publish,timemodified) values(4,'name4','text4',4,'4','4','4','4','4','4',4,4);
|
||||
|
||||
select * from prefix_choice order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table choice_answers
|
||||
rem
|
||||
|
||||
drop TABLE prefix_choice_answers;
|
||||
CREATE TABLE prefix_choice_answers (
|
||||
id number(10) primary key,
|
||||
choice number(10) default '0' not null,
|
||||
userid number(10) default '0' not null,
|
||||
answer number(4) default '0' not null,
|
||||
timemodified number(10) default '0' not null
|
||||
);
|
||||
|
||||
comment on table prefix_choice_answers is 'Answers for each choice';
|
||||
|
||||
drop sequence p_choice_answers_seq;
|
||||
create sequence p_choice_answers_seq;
|
||||
|
||||
create or replace trigger p_choice_answers_trig
|
||||
before insert on prefix_choice_answers
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_choice_answers_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_choice_answers (choice,userid,answer,timemodified) values(1,1,1,1);
|
||||
insert into prefix_choice_answers (choice,userid,answer,timemodified) values(2,2,2,2);
|
||||
insert into prefix_choice_answers (choice,userid,answer,timemodified) values(3,3,3,3);
|
||||
insert into prefix_choice_answers (choice,userid,answer,timemodified) values(4,4,4,4);
|
||||
|
||||
select * from prefix_choice_answers order by 1,2;
|
||||
|
||||
rem
|
||||
rem Dumping data for table log_display
|
||||
rem
|
||||
|
||||
delete from prefix_log_display where module = 'choice';
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('choice', 'view', 'choice', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('choice', 'update', 'choice', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('choice', 'add', 'choice', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('choice', 'report', 'choice', 'name');
|
||||
|
||||
|
||||
|
||||
|
@ -1,219 +0,0 @@
|
||||
rem
|
||||
rem Table structure for table exercise
|
||||
rem
|
||||
|
||||
drop TABLE prefix_exercise;
|
||||
CREATE TABLE prefix_exercise (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' not null,
|
||||
name varchar2(255) default '' not null,
|
||||
nelements number(3) default '1' not null,
|
||||
phase number(3) default '0' not null,
|
||||
gradingstrategy number(3) default '1' not null,
|
||||
usemaximum number(3) default '0' not null,
|
||||
assessmentcomps number(3) default '2' not null,
|
||||
anonymous number(3) default '0' not null,
|
||||
maxbytes number(10) default '100000' not null,
|
||||
deadline number(10) default '0' not null,
|
||||
grade number(3) default '0' not null,
|
||||
timemodified number(10) default '0' not null,
|
||||
teacherweight number(3) default '5' not null,
|
||||
gradingweight number(3) default '5' not null,
|
||||
showleaguetable number(3) default '0' not null
|
||||
);
|
||||
|
||||
COMMENT on table prefix_exercise is 'Defines exercise';
|
||||
|
||||
drop sequence prefix_exercise_seq;
|
||||
create sequence prefix_exercise_seq;
|
||||
|
||||
create or replace trigger p_exercise_trig
|
||||
before insert on prefix_exercise
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select prefix_exercise_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table exercise_submissions
|
||||
rem
|
||||
|
||||
drop TABLE prefix_exercise_submissions;
|
||||
CREATE TABLE prefix_exercise_submissions (
|
||||
id number(10) primary key,
|
||||
exerciseid number(10) default '0',
|
||||
userid number(10) default '0',
|
||||
title varchar2(100) default '',
|
||||
timecreated number(10) default '0',
|
||||
resubmit number(3) default '0',
|
||||
mailed number(3) default '0',
|
||||
isexercise number(3) default '0',
|
||||
late number(3) default '0'
|
||||
);
|
||||
|
||||
COMMENT on table prefix_exercise_submissions is 'Info about submitted work from teacher and students';
|
||||
|
||||
create INDEX pes_ix on prefix_exercise_submissions(userid);
|
||||
|
||||
drop sequence prefix_exercise_submissions_sq;
|
||||
create sequence prefix_exercise_submissions_sq;
|
||||
|
||||
create or replace trigger p_exercise_submissions_trig
|
||||
before insert on prefix_exercise_submissions
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select prefix_exercise_submissions_sq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table exercise_assessments
|
||||
rem
|
||||
|
||||
drop TABLE prefix_exercise_assessments;
|
||||
CREATE TABLE prefix_exercise_assessments (
|
||||
id number(10) primary key,
|
||||
exerciseid number(10) default '0',
|
||||
submissionid number(10) default '0',
|
||||
userid number(10) default '0',
|
||||
timecreated number(10) default '0',
|
||||
timegraded number(10) default '0',
|
||||
grade float default '0',
|
||||
gradinggrade number(3) default '0',
|
||||
mailed number(2) default '0',
|
||||
generalcomment varchar2(1024),
|
||||
teachercomment varchar2(1024)
|
||||
);
|
||||
|
||||
COMMENT on table prefix_exercise_assessments is 'Info about assessments by teacher and students';
|
||||
|
||||
drop sequence prefix_exercise_assessments_sq;
|
||||
create sequence prefix_exercise_assessments_sq;
|
||||
|
||||
create or replace trigger p_exercise_assessments_trig
|
||||
before insert on prefix_exercise_assessments
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select prefix_exercise_assessments_sq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
|
||||
create INDEX eas_ix on prefix_exercise_assessments(submissionid);
|
||||
create INDEX eau_ix on prefix_exercise_assessments (userid);
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table exercise_elements
|
||||
rem
|
||||
|
||||
drop TABLE prefix_exercise_elements;
|
||||
CREATE TABLE prefix_exercise_elements (
|
||||
id number(10) primary key,
|
||||
exerciseid number(10) default '0',
|
||||
elementno number(3) default '0',
|
||||
description varchar2(1024),
|
||||
scale number(3) default '0',
|
||||
maxscore number(3) default '1',
|
||||
weight number(3) default '11'
|
||||
);
|
||||
|
||||
COMMENT on table prefix_exercise_elements is 'Info about marking scheme of assignment';
|
||||
|
||||
drop sequence prefix_exercise_elements_seq;
|
||||
create sequence prefix_exercise_elements_seq;
|
||||
|
||||
create or replace trigger p_exercise_elements_trig
|
||||
before insert on prefix_exercise_elements
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select prefix_exercise_elements_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
|
||||
rem
|
||||
rem Table structure for table exercise_rubrics
|
||||
rem
|
||||
|
||||
drop TABLE prefix_exercise_rubrics;
|
||||
CREATE TABLE prefix_exercise_rubrics (
|
||||
id number(10) primary key,
|
||||
exerciseid number(10) default '0',
|
||||
elementno number(10) default '0',
|
||||
rubricno number(3) default '0',
|
||||
description varchar2(1024)
|
||||
);
|
||||
|
||||
COMMENT on table prefix_exercise_rubrics is 'Info about the rubrics marking scheme';
|
||||
|
||||
drop sequence prefix_exercise_rubrics_seq;
|
||||
create sequence prefix_exercise_rubrics_seq;
|
||||
|
||||
create or replace trigger p_exercise_rubrics_trig
|
||||
before insert on prefix_exercise_rubrics
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select prefix_exercise_rubrics_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table exercise_grades
|
||||
rem
|
||||
|
||||
drop TABLE prefix_exercise_grades;
|
||||
CREATE TABLE prefix_exercise_grades (
|
||||
id number(10) primary key,
|
||||
exerciseid number(10) default '0',
|
||||
assessmentid number(10) default '0',
|
||||
elementno number(10) default '0',
|
||||
feedback varchar2(1024) default '',
|
||||
grade number(3) default '0'
|
||||
);
|
||||
|
||||
COMMENT on table prefix_exercise_grades is 'Info about individual grades given to each element';
|
||||
|
||||
drop sequence prefix_exercise_grades_seq;
|
||||
create sequence prefix_exercise_grades_seq;
|
||||
|
||||
create or replace trigger p_exercise_grades_trig
|
||||
before insert on prefix_exercise_grades
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select prefix_exercise_grades_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
|
||||
create INDEX ega_idx on prefix_exercise_grades (assessmentid);
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('exercise', 'close', 'exercise', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('exercise', 'open', 'exercise', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('exercise', 'submit', 'exercise', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('exercise', 'view', 'exercise', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('exercise', 'update', 'exercise', 'name');
|
||||
|
@ -1,13 +0,0 @@
|
||||
<?php
|
||||
|
||||
function forum_upgrade($oldversion) {
|
||||
// This function does anything necessary to upgrade
|
||||
// older versions to match current functionality
|
||||
|
||||
global $CFG;
|
||||
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
?>
|
@ -1,217 +0,0 @@
|
||||
rem
|
||||
rem Table structure for table forum
|
||||
rem
|
||||
|
||||
drop TABLE prefix_forum;
|
||||
CREATE TABLE prefix_forum (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' NOT NULL,
|
||||
type varchar2(64) default 'general' not null,
|
||||
constraint type_check CHECK (type IN (
|
||||
'single','news','general','social','eachuser','teacher')),
|
||||
name varchar2(255) default '' not null,
|
||||
intro varchar2(1024) NOT NULL,
|
||||
open number(2) default '2' not null,
|
||||
assessed number(10) default '0' NOT NULL,
|
||||
scale number(10) default '0' NOT NULL,
|
||||
maxbytes number(10) default '0' NOT NULL,
|
||||
forcesubscribe number(1) default '0' NOT NULL,
|
||||
rsstype number(2) default '0' NOT NULL,
|
||||
rssarticles number(2) default '0' NOT NULL,
|
||||
timemodified number(10) default '0' NOT NULL
|
||||
);
|
||||
|
||||
COMMENT on table prefix_forum is 'Forums contain and structure discussion';
|
||||
|
||||
drop sequence p_forum_seq;
|
||||
create sequence p_forum_seq;
|
||||
|
||||
create or replace trigger p_forum_trig
|
||||
before insert on prefix_forum
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_forum_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_forum(course,type,name,intro,open,assessed,scale,forcesubscribe,timemodified) values(1,'single','1','1',1,1,1,1,1);
|
||||
insert into prefix_forum(course,type,name,intro,open,assessed,scale,forcesubscribe,timemodified) values(2,'general','2','2',2,2,2,2,2);
|
||||
insert into prefix_forum(course,type,name,intro,open,assessed,scale,forcesubscribe,timemodified) values(3,'eachuser','3','3',3,3,3,3,3);
|
||||
rem should fail the check constraint
|
||||
insert into prefix_forum(course,type,name,intro,open,assessed,scale,forcesubscribe,timemodified) values(4,'4','4','4',4,4,4,4,4);
|
||||
|
||||
select * from prefix_forum order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
rem
|
||||
rem Table structure for table forum_discussions
|
||||
rem
|
||||
|
||||
drop TABLE prefix_forum_discussions;
|
||||
CREATE TABLE prefix_forum_discussions (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' NOT NULL,
|
||||
forum number(10) default '0' NOT NULL,
|
||||
name varchar2(255) default '' not null,
|
||||
firstpost number(10) default '0' NOT NULL,
|
||||
assessed number(1) default '1' not null,
|
||||
timemodified number(10) default '0' NOT NULL
|
||||
);
|
||||
|
||||
COMMENT on table prefix_forum_discussions is 'Forums are composed of discussions';
|
||||
|
||||
drop sequence p_forum_disc_seq;
|
||||
create sequence p_forum_disc_seq;
|
||||
|
||||
create or replace trigger p_forum_disc_trig
|
||||
before insert on prefix_forum_discussions
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_forum_disc_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_forum_discussions(course,forum,name,firstpost,assessed,timemodified) values(1,1,'1',1,1,1);
|
||||
insert into prefix_forum_discussions(course,forum,name,firstpost,assessed,timemodified) values(2,2,'2',2,2,2);
|
||||
insert into prefix_forum_discussions(course,forum,name,firstpost,assessed,timemodified) values(3,3,'3',3,3,3);
|
||||
insert into prefix_forum_discussions(course,forum,name,firstpost,assessed,timemodified) values(4,4,'4',4,4,4);
|
||||
|
||||
select * from prefix_forum_discussions order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
rem
|
||||
rem Table structure for table forum_posts
|
||||
rem
|
||||
|
||||
drop TABLE prefix_forum_posts;
|
||||
CREATE TABLE prefix_forum_posts (
|
||||
id number(10) primary key,
|
||||
discussion number(10) default '0' NOT NULL,
|
||||
parent number(10) default '0' NOT NULL,
|
||||
userid number(10) default '0' NOT NULL,
|
||||
created number(10) default '0' NOT NULL,
|
||||
modified number(10) default '0' NOT NULL,
|
||||
mailed number(2) default '0' NOT NULL,
|
||||
subject varchar2(255) default '' not null,
|
||||
message varchar2(1024) NOT NULL,
|
||||
format number(2) default '0' NOT NULL,
|
||||
attachment varchar2(100) default '' not null,
|
||||
totalscore number(4) default '0' NOT NULL
|
||||
);
|
||||
|
||||
drop sequence p_forum_posts_seq;
|
||||
create sequence p_forum_posts_seq;
|
||||
|
||||
create or replace trigger p_forum_posts_trig
|
||||
before insert on prefix_forum_posts
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_forum_posts_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
COMMENT on table prefix_forum_posts is 'All posts are stored in this table';
|
||||
|
||||
insert into prefix_forum_posts (discussion,parent,userid,created,modified,mailed,subject,message,format,attachment,totalscore) values(1,1,1,1,1,1,'1','1',1,'1',1);
|
||||
insert into prefix_forum_posts (discussion,parent,userid,created,modified,mailed,subject,message,format,attachment,totalscore) values(2,2,2,2,2,2,'2','2',2,'2',2);
|
||||
insert into prefix_forum_posts (discussion,parent,userid,created,modified,mailed,subject,message,format,attachment,totalscore) values(3,3,3,3,3,3,'3','3',3,'3',3);
|
||||
insert into prefix_forum_posts (discussion,parent,userid,created,modified,mailed,subject,message,format,attachment,totalscore) values(4,4,4,4,4,4,'4','4',4,'4',4);
|
||||
|
||||
select * from prefix_forum_posts order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
rem
|
||||
rem Table structure for table forum_ratings
|
||||
rem
|
||||
|
||||
drop TABLE prefix_forum_ratings;
|
||||
CREATE TABLE prefix_forum_ratings (
|
||||
id number(10) primary key,
|
||||
userid number(10) default '0' NOT NULL,
|
||||
post number(10) default '0' NOT NULL,
|
||||
time number(10) default '0' NOT NULL,
|
||||
rating number(4) default '0' NOT NULL
|
||||
);
|
||||
|
||||
drop sequence p_forum_ratings_seq;
|
||||
create sequence p_forum_ratings_seq;
|
||||
|
||||
create or replace trigger p_forum_ratings_trig
|
||||
before insert on prefix_forum_ratings
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_forum_ratings_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
COMMENT on table prefix_forum_ratings is 'Contains user ratings for individual posts';
|
||||
|
||||
insert into prefix_forum_ratings(userid,post,time,rating) values(1,1,1,1);
|
||||
insert into prefix_forum_ratings(userid,post,time,rating) values(2,2,2,2);
|
||||
insert into prefix_forum_ratings(userid,post,time,rating) values(3,3,3,3);
|
||||
insert into prefix_forum_ratings(userid,post,time,rating) values(4,4,4,4);
|
||||
|
||||
select * from prefix_forum_ratings order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
rem
|
||||
rem Table structure for table forum_subscriptions
|
||||
rem
|
||||
|
||||
drop TABLE prefix_forum_subscriptions;
|
||||
CREATE TABLE prefix_forum_subscriptions (
|
||||
id number(10) primary key,
|
||||
userid number(10) default '0' NOT NULL,
|
||||
forum number(10) default '0' NOT NULL
|
||||
);
|
||||
|
||||
drop sequence p_forum_subscrip_seq;
|
||||
create sequence p_forum_subscrip_seq;
|
||||
|
||||
create or replace trigger p_forum_subscrip_trig
|
||||
before insert on prefix_forum_subscriptions
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_forum_subscrip_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
COMMENT on table prefix_forum_subscriptions is 'Keeps track of who is subscribed to what forum';
|
||||
|
||||
insert into prefix_forum_subscriptions(userid,forum) values(1,1);
|
||||
insert into prefix_forum_subscriptions(userid,forum) values(2,2);
|
||||
insert into prefix_forum_subscriptions(userid,forum) values(3,3);
|
||||
insert into prefix_forum_subscriptions(userid,forum) values(4,4);
|
||||
|
||||
select * from prefix_forum_subscriptions order by 1,2;
|
||||
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Dumping data for table log_display
|
||||
rem
|
||||
delete from prefix_log_display where module = 'forum';
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'add', 'forum', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'update', 'forum', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'add discussion', 'forum_discussions', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'add post', 'forum_posts', 'subject');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'update post', 'forum_posts', 'subject');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'move discussion', 'forum_discussions', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'view subscribers', 'forum', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'view discussion', 'forum_discussions', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'view forum', 'forum', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'subscribe', 'forum', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('forum', 'unsubscribe', 'forum', 'name');
|
||||
|
||||
select * from prefix_log_display where module = 'forum';
|
@ -1,28 +0,0 @@
|
||||
<?php // $Id$
|
||||
|
||||
|
||||
|
||||
function glossary_upgrade($oldversion) {
|
||||
|
||||
/// This function does anything necessary to upgrade
|
||||
|
||||
/// older versions to match current functionality
|
||||
|
||||
|
||||
|
||||
global $CFG;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
?>
|
||||
|
||||
|
||||
|
@ -1,174 +0,0 @@
|
||||
rem This file contains a complete database schema for all the
|
||||
rem tables used by this module, written in SQL
|
||||
|
||||
rem It may also contain INSERT statements for particular data
|
||||
rem that may be used, especially new entries in the table log_display
|
||||
|
||||
rem
|
||||
rem Table structure for table glossary
|
||||
rem
|
||||
|
||||
drop TABLE prefix_glossary;
|
||||
CREATE TABLE prefix_glossary (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' not null,
|
||||
name varchar2(255) default '' not null,
|
||||
intro varchar2(255) default '' not null,
|
||||
studentcanpost number(2) default '0' not null,
|
||||
allowduplicatedentries number(2) default '0' not null,
|
||||
displayformat number(2) default '0' not null,
|
||||
mainglossary number(2) default '0' not null,
|
||||
showspecial number(2) default '1' not null,
|
||||
showall number(2) default '1' not null,
|
||||
showalphabet number(2) default '1' not null,
|
||||
editalways number(2) default '0' NOT NULL,
|
||||
rsstype number(2) default '0' NOT NULL,
|
||||
rssarticles number(2) default '0' NOT NULL,
|
||||
timecreated number(10) default '0' not null,
|
||||
timemodified number(10) default '0' not null
|
||||
);
|
||||
|
||||
COMMENT on table prefix_glossary is 'all glossaries';
|
||||
|
||||
drop sequence p_glossary_seq;
|
||||
create sequence p_glossary_seq;
|
||||
|
||||
create or replace trigger p_glossary_trig
|
||||
before insert on prefix_glossary
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_glossary_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_glossary(course,name,intro,studentcanpost,allowduplicatedentries,displayformat,mainglossary,showspecial,showall,showalphabet,timecreated,timemodified) values(1,'1','1',1,1,1,1,1,1,1,1,1);
|
||||
insert into prefix_glossary(course,name,intro,studentcanpost,allowduplicatedentries,displayformat,mainglossary,showspecial,showall,showalphabet,timecreated,timemodified) values(2,'2','2',2,2,2,2,2,2,2,2,2);
|
||||
insert into prefix_glossary(course,name,intro,studentcanpost,allowduplicatedentries,displayformat,mainglossary,showspecial,showall,showalphabet,timecreated,timemodified) values(3,'3','3',3,3,3,3,3,3,3,3,3);
|
||||
insert into prefix_glossary(course,name,intro,studentcanpost,allowduplicatedentries,displayformat,mainglossary,showspecial,showall,showalphabet,timecreated,timemodified) values(4,'4','4',4,4,4,4,4,4,4,4,4);
|
||||
|
||||
select * from prefix_glossary order by 1,2;
|
||||
|
||||
rem
|
||||
rem Table structure for table glossary_entries
|
||||
rem
|
||||
|
||||
drop TABLE prefix_glossary_entries;
|
||||
CREATE TABLE prefix_glossary_entries (
|
||||
id number(10) primary key,
|
||||
glossaryid number(10) default '0' not null,
|
||||
userid number(10) default '0' not null,
|
||||
concept varchar2(255) default '' not null,
|
||||
definition varchar2(1024) NOT NULL,
|
||||
format number(2) default '0' not null,
|
||||
attachment varchar2(100) default '' not null,
|
||||
timecreated number(10) default '0' not null,
|
||||
timemodified number(10) default '0' not null,
|
||||
teacherentry number(2) default '0' not null,
|
||||
sourceglossaryid number(10) default '0' not null
|
||||
);
|
||||
|
||||
COMMENT on table prefix_glossary_entries is 'all glossary entries';
|
||||
|
||||
drop sequence p_glossary_entries_seq;
|
||||
create sequence p_glossary_entries_seq;
|
||||
|
||||
create or replace trigger p_glossary_entries_trig
|
||||
before insert on prefix_glossary_entries
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_glossary_entries_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_glossary_entries(glossaryid,userid,concept,definition,format,attachment,timecreated,timemodified,teacherentry,sourceglossaryid) values(1,1,'1','1',1,'1',1,1,1,1);
|
||||
insert into prefix_glossary_entries(glossaryid,userid,concept,definition,format,attachment,timecreated,timemodified,teacherentry,sourceglossaryid) values(2,2,'2','2',2,'2',2,2,2,2);
|
||||
insert into prefix_glossary_entries(glossaryid,userid,concept,definition,format,attachment,timecreated,timemodified,teacherentry,sourceglossaryid) values(3,3,'3','3',3,'3',3,3,3,3);
|
||||
insert into prefix_glossary_entries(glossaryid,userid,concept,definition,format,attachment,timecreated,timemodified,teacherentry,sourceglossaryid) values(4,4,'4','4',4,'4',4,4,4,4);
|
||||
|
||||
col format format 99
|
||||
select * from prefix_glossary_entries order by 1,2;
|
||||
|
||||
rem
|
||||
rem Table structure for table glossary_cageories
|
||||
rem
|
||||
|
||||
drop TABLE prefix_glossary_categories;
|
||||
CREATE TABLE prefix_glossary_categories (
|
||||
id number(10) primary key,
|
||||
glossaryid number(10) default '0' not null,
|
||||
name varchar(255) default '' not null
|
||||
);
|
||||
|
||||
COMMENT on table prefix_glossary_categories is 'all categories for glossary entries';
|
||||
|
||||
drop sequence p_glossary_categories_seq;
|
||||
create sequence p_glossary_categories_seq;
|
||||
|
||||
create or replace trigger p_glossary_categories_trig
|
||||
before insert on prefix_glossary_categories
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_glossary_categories_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_glossary_categories(glossaryid,name) values(1,'1');
|
||||
insert into prefix_glossary_categories(glossaryid,name) values(2,'2');
|
||||
insert into prefix_glossary_categories(glossaryid,name) values(3,'3');
|
||||
insert into prefix_glossary_categories(glossaryid,name) values(4,'4');
|
||||
|
||||
rem
|
||||
rem Table structure for table glossary_entries_category
|
||||
rem
|
||||
|
||||
drop TABLE prefix_glossary_entries_catego;
|
||||
CREATE TABLE prefix_glossary_entries_catego (
|
||||
id number(10) primary key,
|
||||
categoryid number(10) default '0' not null,
|
||||
entryid number(10) default '0' not null
|
||||
);
|
||||
|
||||
COMMENT on table prefix_glossary_entries_catego is 'categories of each glossary entry';
|
||||
|
||||
drop sequence pg_entries_catego_seq;
|
||||
create sequence pg_entries_catego_seq;
|
||||
|
||||
create or replace trigger pg_entries_catego_trig
|
||||
before insert on prefix_glossary_entries_catego
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select pg_entries_catego_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_glossary_entries_catego(categoryid,entryid) values(1,1);
|
||||
insert into prefix_glossary_entries_catego(categoryid,entryid) values(2,2);
|
||||
insert into prefix_glossary_entries_catego(categoryid,entryid) values(3,3);
|
||||
insert into prefix_glossary_entries_catego(categoryid,entryid) values(4,4);
|
||||
|
||||
rem
|
||||
rem Dumping data for table log_display
|
||||
rem
|
||||
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'add', 'glossary', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'update', 'glossary', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'delete', 'glossary', 'name');
|
||||
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'view', 'glossary', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'view all', 'glossary', 'name');
|
||||
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'add entry', 'glossary', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'update entry', 'glossary', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'delete entry', 'glossary', 'name');
|
||||
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'add category', 'glossary', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'update category', 'glossary', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('glossary', 'delete category', 'glossary', 'name');
|
@ -1,24 +0,0 @@
|
||||
<?php
|
||||
|
||||
|
||||
|
||||
function journal_upgrade($oldversion) {
|
||||
|
||||
/// This function does anything necessary to upgrade
|
||||
|
||||
/// older versions to match current functionality
|
||||
|
||||
|
||||
|
||||
global $CFG;
|
||||
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
?>
|
||||
|
||||
|
||||
|
@ -1,89 +0,0 @@
|
||||
rem
|
||||
rem Table structure for table journal
|
||||
rem
|
||||
|
||||
drop TABLE prefix_journal;
|
||||
CREATE TABLE prefix_journal (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' not null,
|
||||
name varchar(255) default NULL,
|
||||
intro varchar2(1024),
|
||||
days number(5) default '7' not null,
|
||||
assessed number(10) default '0' not null,
|
||||
timemodified number(10) default '0' not null
|
||||
);
|
||||
|
||||
drop sequence p_journal_seq;
|
||||
create sequence p_journal_seq;
|
||||
|
||||
create or replace trigger p_journal_trig
|
||||
before insert on prefix_journal
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_journal_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_journal(course,name,intro,days,assessed,timemodified) values(1,'1','1',1,1,1);
|
||||
insert into prefix_journal(course,name,intro,days,assessed,timemodified) values(2,'2','2',2,2,2);
|
||||
insert into prefix_journal(course,name,intro,days,assessed,timemodified) values(3,'3','3',3,3,3);
|
||||
insert into prefix_journal(course,name,intro,days,assessed,timemodified) values(4,'4','4',4,4,4);
|
||||
|
||||
select * from prefix_journal order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table journal_entries
|
||||
rem
|
||||
|
||||
drop TABLE prefix_journal_entries;
|
||||
CREATE TABLE prefix_journal_entries (
|
||||
id number(10) primary key,
|
||||
journal number(10) default '0' not null,
|
||||
userid number(10) default '0' not null,
|
||||
modified number(10) default '0' not null,
|
||||
text varchar2(1024) NOT NULL,
|
||||
format number(2) default '0' not null,
|
||||
rating number(10) default '0',
|
||||
commentt varchar2(1024),
|
||||
teacher number(10) default '0' not null,
|
||||
timemarked number(10) default '0' not null,
|
||||
mailed number(1) default '0' not null
|
||||
);
|
||||
|
||||
comment on table prefix_journal_entries is 'All the journal entries of all people';
|
||||
|
||||
drop sequence p_journal_entries_seq;
|
||||
create sequence p_journal_entries_seq;
|
||||
|
||||
create or replace trigger p_journal_entries_trig
|
||||
before insert on prefix_journal_entries
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_journal_entries_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_journal_entries(journal,userid,modified,text,format,rating,commentt,teacher,timemarked,mailed) values(1,1,1,'1',1,1,'1',1,1,1);
|
||||
insert into prefix_journal_entries(journal,userid,modified,text,format,rating,commentt,teacher,timemarked,mailed) values(2,2,2,'2',2,2,'2',2,2,2);
|
||||
insert into prefix_journal_entries(journal,userid,modified,text,format,rating,commentt,teacher,timemarked,mailed) values(3,3,3,'3',3,3,'3',3,3,3);
|
||||
insert into prefix_journal_entries(journal,userid,modified,text,format,rating,commentt,teacher,timemarked,mailed) values(4,4,4,'4',4,4,'4',4,4,4);
|
||||
|
||||
select * from prefix_journal_entries order by 1,2;
|
||||
|
||||
rem
|
||||
rem Dumping data for table log_display
|
||||
rem
|
||||
delete from prefix_log_display where module = 'journal';
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('journal', 'view', 'journal', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('journal', 'add entry', 'journal', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('journal', 'update entry', 'journal', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('journal', 'view responses', 'journal', 'name');
|
||||
|
||||
col module format a10
|
||||
select * from prefix_log_display where module = 'journal';
|
@ -1,30 +0,0 @@
|
||||
drop TABLE prefix_label;
|
||||
CREATE TABLE prefix_label (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' not null,
|
||||
name varchar2(255) default '' not null,
|
||||
content varchar2(1024) NOT NULL,
|
||||
timemodified number(10) default '0' not null
|
||||
);
|
||||
|
||||
COMMENT on table prefix_label is 'Defines labels';
|
||||
|
||||
drop sequence p_label_seq;
|
||||
create sequence p_label_seq;
|
||||
|
||||
create or replace trigger p_label_trig
|
||||
before insert on prefix_label
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_label_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_label(course,name,content,timemodified) values(1,'1','1',1);
|
||||
insert into prefix_label(course,name,content,timemodified) values(2,'2','2',2);
|
||||
insert into prefix_label(course,name,content,timemodified) values(3,'3','3',3);
|
||||
insert into prefix_label(course,name,content,timemodified) values(4,'4','4',4);
|
||||
|
||||
select * from prefix_label order by 1,2;
|
@ -1,13 +0,0 @@
|
||||
<?php
|
||||
|
||||
function resource_upgrade($oldversion) {
|
||||
// This function does anything necessary to upgrade
|
||||
// older versions to match current functionality
|
||||
|
||||
global $CFG;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
|
@ -1,45 +0,0 @@
|
||||
rem
|
||||
rem Table structure for table resource
|
||||
rem
|
||||
|
||||
drop TABLE prefix_resource;
|
||||
CREATE TABLE prefix_resource (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' not null,
|
||||
name varchar2(255) default '' not null,
|
||||
type number(4) default '0' not null,
|
||||
reference varchar2(255) default NULL,
|
||||
summary varchar2(1024) NOT NULL,
|
||||
alltext varchar2(1024) NOT NULL,
|
||||
timemodified number(10) default '0' not null
|
||||
);
|
||||
|
||||
drop sequence p_resource_seq;
|
||||
create sequence p_resource_seq;
|
||||
|
||||
create or replace trigger p_resource_trig
|
||||
before insert on prefix_resource
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_resource_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
comment on table prefix_resource is 'table of resources';
|
||||
|
||||
insert into prefix_resource(course,name,type,reference,summary,alltext,timemodified) values(1,'1',1,1,'1','1',1);
|
||||
insert into prefix_resource(course,name,type,reference,summary,alltext,timemodified) values(2,'2',2,2,'2','2',2);
|
||||
insert into prefix_resource(course,name,type,reference,summary,alltext,timemodified) values(3,'3',3,3,'3','3',3);
|
||||
insert into prefix_resource(course,name,type,reference,summary,alltext,timemodified) values(4,'4',4,4,'4','4',4);
|
||||
|
||||
select * from prefix_resource order by 1,2;
|
||||
|
||||
rem
|
||||
rem Dumping data for table log_display
|
||||
rem
|
||||
|
||||
delete from prefix_log_display where module = 'resource';
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('resource', 'view', 'resource', 'name');
|
||||
select * from prefix_log_display where module = 'resource';
|
@ -1,11 +0,0 @@
|
||||
<?php
|
||||
function survey_upgrade($oldversion) {
|
||||
// This function does anything necessary to upgrade
|
||||
// older versions to match current functionality
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
|
@ -1,227 +0,0 @@
|
||||
rem
|
||||
rem Table structure for table survey
|
||||
rem
|
||||
|
||||
drop TABLE prefix_survey;
|
||||
CREATE TABLE prefix_survey (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' not null,
|
||||
template number(10) default '0' not null,
|
||||
days number(6) default '0' not null,
|
||||
timecreated number(10) default '0' not null,
|
||||
timemodified number(10) default '0' not null,
|
||||
name varchar2(255) default '' not null,
|
||||
intro varchar2(1024),
|
||||
questions varchar2(255) default NULL
|
||||
);
|
||||
|
||||
drop sequence p_survey_seq;
|
||||
create sequence p_survey_seq;
|
||||
|
||||
create or replace trigger p_survey_trig
|
||||
before insert on prefix_survey
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_survey_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
COMMENT on table prefix_survey is 'all surveys';
|
||||
|
||||
INSERT INTO prefix_survey (course, template, days, timecreated, timemodified, name, intro, questions) VALUES (0, 0, 0, 985017600, 985017600, 'collesaname', 'collesaintro', '25,26,27,28,29,30,43,44');
|
||||
INSERT INTO prefix_survey (course, template, days, timecreated, timemodified, name, intro, questions) VALUES (0, 0, 0, 985017600, 985017600, 'collespname', 'collespintro', '31,32,33,34,35,36,43,44');
|
||||
INSERT INTO prefix_survey (course, template, days, timecreated, timemodified, name, intro, questions) VALUES (0, 0, 0, 985017600, 985017600, 'collesapname', 'collesapintro', '37,38,39,40,41,42,43,44');
|
||||
INSERT INTO prefix_survey (course, template, days, timecreated, timemodified, name, intro, questions) VALUES (0, 0, 0, 985017600, 985017600, 'attlsname', 'attlsintro', '65,67,68');
|
||||
|
||||
select * from prefix_survey order by 1,2;
|
||||
|
||||
rem
|
||||
rem Table structure for table survey_analysis
|
||||
rem
|
||||
|
||||
drop TABLE prefix_survey_analysis;
|
||||
CREATE TABLE prefix_survey_analysis (
|
||||
id number(10) primary key,
|
||||
survey number(10) default '0' not null,
|
||||
userid number(10) default '0' not null,
|
||||
notes varchar2(1024) NOT NULL
|
||||
|
||||
drop sequence p_survey_analysis_seq;
|
||||
create sequence p_survey_analysis_seq;
|
||||
|
||||
create or replace trigger p_survey_analysis_trig
|
||||
before insert on prefix_survey_analysis
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_survey_analysis_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
);
|
||||
|
||||
comment on table prefix_survey_analysis is 'Survey analysis';
|
||||
|
||||
rem
|
||||
rem Dumping data for table survey_analysis
|
||||
rem
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table survey_answers
|
||||
rem
|
||||
|
||||
drop TABLE prefix_survey_answers;
|
||||
CREATE TABLE prefix_survey_answers (
|
||||
id number(10) primary key,
|
||||
userid number(10) default '0' not null,
|
||||
survey number(10) default '0' not null,
|
||||
question number(10) default '0' not null,
|
||||
time number(10) default NULL,
|
||||
answer1 varchar2(255) default NULL,
|
||||
answer2 varchar2(255) default NULL
|
||||
);
|
||||
|
||||
drop sequence p_survey_answers_seq;
|
||||
create sequence p_survey_answers_seq;
|
||||
|
||||
create or replace trigger p_survey_answers_trig
|
||||
before insert on prefix_survey_answers
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_survey_answers_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
|
||||
rem
|
||||
rem Dumping data for table survey_answers
|
||||
rem
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table survey_questions
|
||||
rem
|
||||
|
||||
drop TABLE prefix_survey_questions;
|
||||
CREATE TABLE prefix_survey_questions (
|
||||
id number(10) primary key,
|
||||
text varchar2(255) default '' not null,
|
||||
shorttext varchar2(30) default '' not null,
|
||||
multi varchar2(100) default '' not null,
|
||||
intro varchar2(50) default NULL,
|
||||
type number(3) default '0' not null,
|
||||
options varchar2(1024)
|
||||
);
|
||||
|
||||
comment on table prefix_survey_questions is 'structure for survey_questions';
|
||||
|
||||
drop sequence p_survey_questions_seq;
|
||||
create sequence p_survey_questions_seq;
|
||||
|
||||
create or replace trigger p_survey_questions_trig
|
||||
before insert on prefix_survey_questions
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_survey_questions_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
rem
|
||||
rem Dumping data for table survey_questions
|
||||
rem
|
||||
|
||||
INSERT INTO prefix_survey_questions ( text, shorttext, multi, intro, type, options) VALUES ('colles1', 'colles1short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles2', 'colles2short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles3', 'colles3short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles4', 'colles4short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles5', 'colles5short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles6', 'colles6short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles7', 'colles7short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles8', 'colles8short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles9', 'colles9short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ( 'colles10', 'colles10short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ( 'colles11', 'colles11short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ( 'colles12', 'colles12short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ( 'colles13', 'colles13short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles14', 'colles14short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles15', 'colles15short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles16', 'colles16short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles17', 'colles17short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles18', 'colles18short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles19', 'colles19short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles20', 'colles20short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles21', 'colles21short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles22', 'colles22short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles23', 'colles23short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('colles24', 'colles24short', '1', '1', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm1', 'collesm1short', '1,2,3,4', 'collesmintro', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm2', 'collesm2short', '5,6,7,8', 'collesmintro', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm3', 'collesm3short', '9,10,11,12', 'collesmintro', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm4', 'collesm4short', '13,14,15,16', 'collesmintro', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm5', 'collesm5short', '17,18,19,20', 'collesmintro', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm6', 'collesm6short', '21,22,23,24', 'collesmintro', 1, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm1', 'collesm1short', '1,2,3,4', 'collesmintro', 2, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm2', 'collesm2short', '5,6,7,8', 'collesmintro', 2, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm3', 'collesm3short', '9,10,11,12', 'collesmintro', 2, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm4', 'collesm4short', '13,14,15,16', 'collesmintro', 2, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm5', 'collesm5short', '17,18,19,20', 'collesmintro', 2, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm6', 'collesm6short', '21,22,23,24', 'collesmintro', 2, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm1', 'collesm1short', '1,2,3,4', 'collesmintro', 3, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm2', 'collesm2short', '5,6,7,8', 'collesmintro', 3, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm3', 'collesm3short', '9,10,11,12', 'collesmintro', 3, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm4', 'collesm4short', '13,14,15,16', 'collesmintro', 3, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm5', 'collesm5short', '17,18,19,20', 'collesmintro', 3, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('collesm6', 'collesm6short', '21,22,23,24', 'collesmintro', 3, 'scaletimes5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('howlong', '1', '1', '1', 1, 'howlongoptions');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('othercomments', '1', '1', '1', 0, '');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls20', 'attls20short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls14', 'attls14short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls15', 'attls15short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls16', 'attls16short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls17', 'attls17short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls18', 'attls18short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls19', 'attls19short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls12', 'attls12short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls13', 'attls13short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls11', 'attls11short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls10', 'attls10short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls9', 'attls9short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls8', 'attls8short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls7', 'attls7short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls6', 'attls6short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls5', 'attls5short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls4', 'attls4short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls3', 'attls3short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls1', 'attls1short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attls2', 'attls2short', '1', '1', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attlsm1', 'attlsm1', '45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64', 'attlsmintro', 1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attlsm2', 'attlsm2', '63,62,59,57,55,49,52,50,48,47', 'attlsmintro', -1, 'scaleagree5');
|
||||
INSERT INTO prefix_survey_questions (text, shorttext, multi, intro, type, options) VALUES ('attlsm3', 'attlsm3', '46,54,45,51,60,53,56,58,61,64', 'attlsmintro', -1, 'scaleagree5');
|
||||
|
||||
rem select * from prefix_survey_questions where text like 'colles%' or text like 'attlsm%'
|
||||
|
||||
col id format 99
|
||||
select * from prefix_survey_questions;
|
||||
|
||||
|
||||
rem
|
||||
rem Dumping data for table log_display
|
||||
rem
|
||||
|
||||
delete from prefix_log_display where module = 'survey';
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('survey', 'download', 'survey', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('survey', 'view form', 'survey', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('survey', 'view graph', 'survey', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('survey', 'view report', 'survey', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('survey', 'submit', 'survey', 'name');
|
||||
select * from prefix_log_display where module = 'survey';
|
@ -1,12 +0,0 @@
|
||||
<?php
|
||||
|
||||
function workshop_upgrade($oldversion) {
|
||||
// This function does anything necessary to upgrade
|
||||
// older versions to match current functionality
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
|
@ -1,318 +0,0 @@
|
||||
rem
|
||||
rem Table structure for table workshop
|
||||
rem
|
||||
|
||||
drop TABLE prefix_workshop;
|
||||
CREATE TABLE prefix_workshop (
|
||||
id number(10) primary key,
|
||||
course number(10) default '0' not null,
|
||||
name varchar2(255) default '' not null,
|
||||
description varchar2(255) NOT NULL,
|
||||
nelements number(3) default '1' not null,
|
||||
phase number(2) default '0' not null,
|
||||
format number(2) default '0' not null,
|
||||
gradingstrategy number(2) default '1' not null,
|
||||
resubmit number(2) default '0' not null,
|
||||
agreeassessments number(2) default '0' not null,
|
||||
hidegrades number(2) default '0' not null,
|
||||
anonymous number(2) default '0' not null,
|
||||
includeself number(2) default '0' not null,
|
||||
maxbytes number(10) default '100000' not null,
|
||||
deadline number(10) default '0' not null,
|
||||
grade number(10) default '0' not null,
|
||||
ntassessments number(3) default '0' not null,
|
||||
nsassessments number(3) default '0' not null,
|
||||
overallocation number(3) default '0' not null,
|
||||
timemodified number(10) default '0' not null,
|
||||
mergegrades number(3) default '0' not null,
|
||||
teacherweight number(3) default '5' NOT NULL,
|
||||
peerweight number(3) default '5' NOT NULL,
|
||||
includeteachersgrade number(3) default '0' not null,
|
||||
biasweight number(3) default '5' NOT NULL,
|
||||
reliabilityweight number(3) default '5' NOT NULL,
|
||||
gradingweight number(3) default '5' NOT NULL,
|
||||
showleaguetable number(3) default '0' not null
|
||||
);
|
||||
|
||||
COMMENT on table prefix_workshop is 'Defines workshop';
|
||||
|
||||
drop sequence p_workshop_seq;
|
||||
create sequence p_workshop_seq;
|
||||
|
||||
create or replace trigger p_workshop_trig
|
||||
before insert on prefix_workshop
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_workshop_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_workshop( course,name,description,nelements,phase,format,gradingstrategy,resubmit,agreeassessments,hidegrades,anonymous,includeself,maxbytes,deadline,grade,ntassessments,nsassessments,timemodified,mergegrades,teacherweight,peerweight,includeteachersgrade,biasweight,reliabilityweight,gradingweight,showleaguetable) values (1,'1','1',1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1);
|
||||
insert into prefix_workshop( course,name,description,nelements,phase,format,gradingstrategy,resubmit,agreeassessments,hidegrades,anonymous,includeself,maxbytes,deadline,grade,ntassessments,nsassessments,timemodified,mergegrades,teacherweight,peerweight,includeteachersgrade,biasweight,reliabilityweight,gradingweight,showleaguetable) values (2,'2','2',2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2);
|
||||
insert into prefix_workshop( course,name,description,nelements,phase,format,gradingstrategy,resubmit,agreeassessments,hidegrades,anonymous,includeself,maxbytes,deadline,grade,ntassessments,nsassessments,timemodified,mergegrades,teacherweight,peerweight,includeteachersgrade,biasweight,reliabilityweight,gradingweight,showleaguetable) values (3,'3','3',3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3);
|
||||
insert into prefix_workshop( course,name,description,nelements,phase,format,gradingstrategy,resubmit,agreeassessments,hidegrades,anonymous,includeself,maxbytes,deadline,grade,ntassessments,nsassessments,timemodified,mergegrades,teacherweight,peerweight,includeteachersgrade,biasweight,reliabilityweight,gradingweight,showleaguetable) values (4,'4','4',4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4);
|
||||
|
||||
col format format 9999
|
||||
select * from prefix_workshop order by 1,2;
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table workshop_submissions
|
||||
rem
|
||||
|
||||
drop TABLE prefix_workshop_submissions;
|
||||
CREATE TABLE prefix_workshop_submissions (
|
||||
id number(10) primary key,
|
||||
workshopid number(10) default '0' not null,
|
||||
userid number(10) default '0' not null,
|
||||
title varchar2(100) default '' not null,
|
||||
timecreated number(10) default '0' not null,
|
||||
mailed number(2) default '0' not null,
|
||||
teachergrade number(3) default '0' not null,
|
||||
peergrade number(3) default '0' not null,
|
||||
biasgrade number(3) default '0' not null,
|
||||
reliabilitygrade number(3) default '0' not null,
|
||||
gradinggrade number(3) default '0' not null,
|
||||
finalgrade number(3) default '0' not null
|
||||
);
|
||||
|
||||
CREATE INDEX title ON prefix_workshop_submissions(title);
|
||||
|
||||
comment on TABLE prefix_workshop_submissions is 'Info about submitted work from teacher and students';
|
||||
|
||||
drop sequence p_workshop_submissions_seq;
|
||||
create sequence p_workshop_submissions_seq;
|
||||
|
||||
create or replace trigger p_workshop_submissions_trig
|
||||
before insert on prefix_workshop_submissions
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_workshop_submissions_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_workshop_submissions ( workshopid,userid,title,timecreated,mailed,teachergrade,peergrade,biasgrade,reliabilitygrade,gradinggrade,finalgrade) values(1,1,'1',1,1,1,1,1,1,1,1);
|
||||
insert into prefix_workshop_submissions ( workshopid,userid,title,timecreated,mailed,teachergrade,peergrade,biasgrade,reliabilitygrade,gradinggrade,finalgrade) values(2,2,'2',2,2,2,2,2,2,2,2);
|
||||
insert into prefix_workshop_submissions ( workshopid,userid,title,timecreated,mailed,teachergrade,peergrade,biasgrade,reliabilitygrade,gradinggrade,finalgrade) values(3,3,'3',3,3,3,3,3,3,3,3);
|
||||
insert into prefix_workshop_submissions ( workshopid,userid,title,timecreated,mailed,teachergrade,peergrade,biasgrade,reliabilitygrade,gradinggrade,finalgrade) values(4,4,'4',4,4,4,4,4,4,4,4);
|
||||
|
||||
select * from prefix_workshop_submissions order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table workshop_assessments
|
||||
rem
|
||||
|
||||
drop TABLE prefix_workshop_assessments;
|
||||
CREATE TABLE prefix_workshop_assessments (
|
||||
id number(10) primary key,
|
||||
workshopid number(10) default '0' not null,
|
||||
submissionid number(10) default '0' not null,
|
||||
userid number(10) default '0' not null,
|
||||
timecreated number(10) default '0' not null,
|
||||
timegraded number(10) default '0' not null,
|
||||
timeagreed number(10) default '0' not null,
|
||||
grade float default '0' not null,
|
||||
gradinggrade number(3) default '0' not null,
|
||||
mailed number(2) default '0' not null,
|
||||
resubmission number(2) default '0' not null,
|
||||
generalcomment varchar2(255) NOT NULL,
|
||||
teachercomment varchar2(255) NOT NULL
|
||||
);
|
||||
|
||||
comment on TABLE prefix_workshop_assessments is 'Info about assessments by teacher and students';
|
||||
|
||||
drop sequence p_workshop_assessments_seq;
|
||||
create sequence p_workshop_assessments_seq;
|
||||
|
||||
create or replace trigger p_workshop_assessments_trig
|
||||
before insert on prefix_workshop_assessments
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_workshop_assessments_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_workshop_assessments (workshopid,submissionid,userid,timecreated,timegraded,timeagreed,grade,gradinggrade,mailed,generalcomment,teachercomment) values(1,1,1,1,1,1,1,1,1,'1','1');
|
||||
insert into prefix_workshop_assessments (workshopid,submissionid,userid,timecreated,timegraded,timeagreed,grade,gradinggrade,mailed,generalcomment,teachercomment) values(2,2,2,2,2,2,2,2,2,'2','2');
|
||||
insert into prefix_workshop_assessments (workshopid,submissionid,userid,timecreated,timegraded,timeagreed,grade,gradinggrade,mailed,generalcomment,teachercomment) values(3,3,3,3,3,3,3,3,3,'3','3');
|
||||
insert into prefix_workshop_assessments (workshopid,submissionid,userid,timecreated,timegraded,timeagreed,grade,gradinggrade,mailed,generalcomment,teachercomment) values(4,4,4,4,4,4,4,4,4,'4','4');
|
||||
|
||||
select * from prefix_workshop_assessments order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table workshop_elements
|
||||
rem
|
||||
|
||||
drop TABLE prefix_workshop_elements;
|
||||
CREATE TABLE prefix_workshop_elements (
|
||||
id number(10) primary key,
|
||||
workshopid number(10) default '0' not null,
|
||||
elementno number(3) default '0' not null,
|
||||
description varchar2(255) NOT NULL,
|
||||
scale number(3) default '0' not null,
|
||||
maxscore number(3) default '1' not null,
|
||||
weight float default '1.0' not null
|
||||
);
|
||||
|
||||
comment on TABLE prefix_workshop_elements is 'Info about marking scheme of assignment';
|
||||
|
||||
drop sequence p_workshop_elements_seq;
|
||||
create sequence p_workshop_elements_seq;
|
||||
|
||||
create or replace trigger p_workshop_elements_trig
|
||||
before insert on prefix_workshop_elements
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_workshop_elements_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_workshop_elements ( workshopid, elementno, description, scale, maxscore, weight) values(1,1,'1',1,1,1);
|
||||
insert into prefix_workshop_elements ( workshopid, elementno, description, scale, maxscore, weight) values(2,2,'2',2,2,2);
|
||||
insert into prefix_workshop_elements ( workshopid, elementno, description, scale, maxscore, weight) values(3,3,'3',3,3,3);
|
||||
insert into prefix_workshop_elements ( workshopid, elementno, description, scale, maxscore, weight) values(4,4,'4',4,4,4);
|
||||
|
||||
select * from prefix_workshop_elements order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table workshop_rubrics
|
||||
rem
|
||||
|
||||
drop TABLE prefix_workshop_rubrics;
|
||||
CREATE TABLE prefix_workshop_rubrics (
|
||||
id number(10) primary key,
|
||||
workshopid number(10) default '0' not null,
|
||||
elementno number(10) default '0' not null,
|
||||
rubricno number(3) default '0' not null,
|
||||
description varchar2(255) NOT NULL
|
||||
);
|
||||
|
||||
comment on TABLE prefix_workshop_rubrics is 'Info about the rubrics marking scheme';
|
||||
|
||||
drop sequence p_workshop_rubrics_seq;
|
||||
create sequence p_workshop_rubrics_seq;
|
||||
|
||||
create or replace trigger p_workshop_rubrics_trig
|
||||
before insert on prefix_workshop_rubrics
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_workshop_rubrics_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_workshop_rubrics ( workshopid,elementno,rubricno,description) values(1,1,1,'1');
|
||||
insert into prefix_workshop_rubrics ( workshopid,elementno,rubricno,description) values(2,2,2,'2');
|
||||
insert into prefix_workshop_rubrics ( workshopid,elementno,rubricno,description) values(3,3,3,'3');
|
||||
insert into prefix_workshop_rubrics ( workshopid,elementno,rubricno,description) values(4,4,4,'4');
|
||||
|
||||
select * from prefix_workshop_rubrics order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table workshop_grades
|
||||
rem
|
||||
|
||||
drop TABLE prefix_workshop_grades;
|
||||
CREATE TABLE prefix_workshop_grades (
|
||||
id number(10) primary key,
|
||||
workshopid number(10) default '0' not null,
|
||||
assessmentid number(10) default '0' not null,
|
||||
elementno number(10) default '0' not null,
|
||||
feedback varchar2(255) default '' not null,
|
||||
grade number(3) default '0' not null
|
||||
);
|
||||
|
||||
comment on TABLE prefix_workshop_grades is 'Info about individual grades given to each element';
|
||||
|
||||
drop sequence p_workshop_grades_seq;
|
||||
create sequence p_workshop_grades_seq;
|
||||
|
||||
create or replace trigger p_workshop_grades_trig
|
||||
before insert on prefix_workshop_grades
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_workshop_grades_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_workshop_grades (workshopid,assessmentid,elementno,feedback,grade) values(1,1,1,'1',1);
|
||||
insert into prefix_workshop_grades (workshopid,assessmentid,elementno,feedback,grade) values(2,2,2,'2',2);
|
||||
insert into prefix_workshop_grades (workshopid,assessmentid,elementno,feedback,grade) values(3,3,3,'3',3);
|
||||
insert into prefix_workshop_grades (workshopid,assessmentid,elementno,feedback,grade) values(4,4,4,'4',4);
|
||||
|
||||
col feedback format a10
|
||||
select * from prefix_workshop_grades order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
rem
|
||||
rem Table structure for table workshop_comments
|
||||
rem
|
||||
|
||||
drop TABLE prefix_workshop_comments;
|
||||
CREATE TABLE prefix_workshop_comments (
|
||||
id number(10) primary key,
|
||||
workshopid number(10) default '0' not null,
|
||||
assessmentid number(10) default '0' not null,
|
||||
userid number(10) default '0' not null,
|
||||
timecreated number(10) default '0' not null,
|
||||
mailed number(2) default '0' not null,
|
||||
comments varchar2(255) NOT NULL
|
||||
);
|
||||
|
||||
comment on TABLE prefix_workshop_comments is 'Defines comments';
|
||||
|
||||
drop sequence p_workshop_comments_seq;
|
||||
create sequence p_workshop_comments_seq;
|
||||
|
||||
create or replace trigger p_workshop_comments_trig
|
||||
before insert on prefix_workshop_comments
|
||||
referencing new as new_row
|
||||
for each row
|
||||
begin
|
||||
select p_workshop_comments_seq.nextval into :new_row.id from dual;
|
||||
end;
|
||||
.
|
||||
/
|
||||
|
||||
insert into prefix_workshop_comments ( workshopid, assessmentid, userid, timecreated, mailed, comments) values(1,1,1,1,1,'1');
|
||||
insert into prefix_workshop_comments ( workshopid, assessmentid, userid, timecreated, mailed, comments) values(2,2,2,2,2,'2');
|
||||
insert into prefix_workshop_comments ( workshopid, assessmentid, userid, timecreated, mailed, comments) values(3,3,3,3,3,'3');
|
||||
insert into prefix_workshop_comments ( workshopid, assessmentid, userid, timecreated, mailed, comments) values(4,4,4,4,4,'4');
|
||||
|
||||
select * from prefix_workshop_comments order by 1,2;
|
||||
|
||||
rem --------------------------------------------------------
|
||||
|
||||
delete from prefix_log_display where module='workshop';
|
||||
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('workshop', 'assess', 'workshop', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('workshop', 'close', 'workshop', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('workshop', 'display grades', 'workshop', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('workshop', 'grade', 'workshop', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('workshop', 'hide grades', 'workshop', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('workshop', 'open', 'workshop', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('workshop', 'submit', 'workshop', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('workshop', 'view', 'workshop', 'name');
|
||||
INSERT INTO prefix_log_display (module, action, mtable, field) VALUES ('workshop', 'update', 'workshop', 'name');
|
||||
|
||||
select * from prefix_log_display where module='workshop' order by 1,2;
|
Loading…
x
Reference in New Issue
Block a user