/* dbload command file for Oracle CAP database:
   in Oracle SQL*Plus, type @dbload */

drop table customers;
create table customers (cid char(4) not null, cname varchar(13),
  city varchar(20), discnt real constraint discnt_max check(discnt <=15.0),
  primary key(cid));

drop table agents;
create table agents (aid char(3) not null, aname varchar(13),
  city varchar(20), percent number(6), primary key(aid));

drop table products;
create table products (pid char(3) not null, pname varchar(13),
  city varchar(20), quantity number(10), price real,
  primary key(pid));

drop table orders;
create table orders (ordno number(6) not null, month char(3),
  cid char(4), aid char(3), pid char(3),
  qty number(6), dollars float, primary key(ordno));
