Here is the script I'm trying to execute:
drop index TestTableIdx1;
drop index TestIdx1;
drop index TestIdx2;
drop table Test;
drop sequence TestSequence;
drop table TestTable;
create table TestTable (
objId number NOT NULL,
type varchar(16) NOT NULL,
title varchar(192) ,
url varchar(192) ,
primary key(objId, type)
);
create table Test (
id number NOT NULL,
objId number NOT NULL,
type varchar(16) NOT NULL,
timeslot timestamp NOT NULL,
contextId number ,
pubId number NOT NULL,
category varchar(24),
meta varchar(32),
pageviews number NOT NULL,
aggrLevel number NOT NULL,
primary key(id)
);
create table Dummy (
id int NOT NULL,
primary key(id)
);
create sequence TestSequence
start with 1
increment by 1
nomaxvalue;
create trigger Test_trigger
before insert on Test
for each row
begin
select TestSequence.nextval into :new.id from dual;
end;
/
create index TestTableIdx1 on TestTable (
objId desc, type asc
);
create index TestIdx1 on Test (
timeslot desc, objId desc, type asc
);
create index TestIdx2 on Test (
timeslot desc
);
create index TestIdx3 on Test (
objId desc, type asc
);
create index TestIdx4 on Test (
contextId desc
);