Line # Revision Author
1 198 ahitrov CREATE TABLE basket (
2 id integer DEFAULT nextval(('public.documents_id_seq'::text)::regclass) NOT NULL,
3 ctime timestamp without time zone DEFAULT now() NOT NULL,
4 mtime timestamp without time zone DEFAULT now() NOT NULL,
5 dtime timestamp without time zone DEFAULT now() NOT NULL,
6 class text DEFAULT 'webshop::Basket'::text NOT NULL,
7 status smallint default 0 NOT NULL,
8 sections integer[],
9 uid integer,
10 item_id integer not null,
11 item_class text,
12 item_table text,
13 order_id integer,
14 color_id integer,
15 session text,
16 number integer default 0,
17 price float default 0,
18 name text,
19 data text
20 );
21
22 CREATE INDEX basket_order_id ON basket USING btree (order_id);
23 CREATE INDEX basket_sections ON basket USING gist (sections);
24 CREATE INDEX basket_session ON basket USING btree (session) where session is not null;
25 CREATE INDEX basket_uid ON basket USING btree (uid);