create table s (
  sno       char(5) not null,
  sname     char(20),
  status    smallint,
  city      char(15),
  unique (sno)
);
create table p (
  pno       char(6) not null,
  pname     char(20),
  color     char(6),
  weight    smallint,
  city      char(15),
  unique (pno)
);
create table j (
  jno       char(4) not null,
  jname     char(10),
  city      char(15),
  unique (jno)
);
create table sp (
  sno       char(5) not null,
  pno       char(6) not null,
  qty       integer,
  unique (sno, pno)
);
create table spj (
  sno       char(5) not null,
  pno       char(6) not null,
  jno       char(4) not null,
  qty       integer,
  unique (sno, pno, jno)
);
