-- Table: calls -- DROP TABLE calls; CREATE TABLE calls ( id serial NOT NULL, log_time timestamp without time zone DEFAULT now(), start_time timestamp(0) without time zone NOT NULL, duration interval(0) NOT NULL, direction character(1) NOT NULL, station integer NOT NULL, line integer, transfer character(1), "number" character(40), "access" character(4), CONSTRAINT calls_pkey PRIMARY KEY (id) ) WITH (OIDS=FALSE); ALTER TABLE calls OWNER TO postgres; GRANT ALL ON TABLE calls TO postgres; GRANT ALL ON TABLE calls TO smdr; -- Index: calls_duration_index -- DROP INDEX calls_duration_index; CREATE INDEX calls_duration_index ON calls USING btree (duration); -- Index: calls_start_time_index -- DROP INDEX calls_start_time_index; CREATE INDEX calls_start_time_index ON calls USING btree (start_time); -- Index: calls_station_index -- DROP INDEX calls_station_index; CREATE INDEX calls_station_index ON calls USING btree (station);