Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- CREATE TABLE public.redemptions
- (
- id integer NOT NULL DEFAULT nextval('redemptions_id_seq'::regclass),
- uuid character varying(255),
- code_value_id integer NOT NULL,
- created_at timestamp without time zone,
- updated_at timestamp without time zone,
- place_id integer,
- user_id integer,
- CONSTRAINT redemptions_pkey PRIMARY KEY (id)
- )
- WITH (
- OIDS=FALSE
- );
- ALTER TABLE public.redemptions
- OWNER TO al1;
- -- Index: public.index_redemptions_on_code_value_id
- -- DROP INDEX public.index_redemptions_on_code_value_id;
- CREATE INDEX index_redemptions_on_code_value_id
- ON public.redemptions
- USING btree
- (code_value_id);
- --------------------------------------------------
- CREATE TABLE public.places
- (
- id integer NOT NULL DEFAULT nextval('backend_place_id_seq'::regclass),
- name character varying(200) NOT NULL,
- geo_fence json,
- external_id character varying(200) NOT NULL,
- city character varying(200),
- country character varying(200),
- bounding_box_north double precision,
- bounding_box_south double precision,
- bounding_box_east double precision,
- bounding_box_west double precision,
- image character varying(100),
- created_at timestamp with time zone NOT NULL,
- updated_at timestamp with time zone NOT NULL,
- latitude double precision,
- longitude double precision,
- image_uid character varying(255),
- image_name character varying(255),
- featured boolean,
- active_benefits_count integer NOT NULL DEFAULT 0,
- radius integer NOT NULL DEFAULT 2000,
- terminal character varying(255),
- deleted_at timestamp without time zone,
- category integer NOT NULL DEFAULT 0,
- street character varying,
- zip character varying,
- twitter character varying,
- push_notification_message text,
- timezone character varying NOT NULL DEFAULT 'UTC'::character varying,
- twitter_boost boolean NOT NULL DEFAULT false,
- push_notification_message_enabled boolean NOT NULL DEFAULT true,
- geojson jsonb,
- push_notification_image_uid character varying,
- searchable boolean NOT NULL DEFAULT true,
- boost integer NOT NULL DEFAULT 0,
- geojson_active boolean DEFAULT false,
- CONSTRAINT backend_place_pkey PRIMARY KEY (id)
- )
- WITH (
- OIDS=FALSE
- );
- ALTER TABLE public.places
- OWNER TO al1;
- -- Index: public.backend_place_bounding_box_east_29b664f93ee940b5_uniq
- -- DROP INDEX public.backend_place_bounding_box_east_29b664f93ee940b5_uniq;
- CREATE INDEX backend_place_bounding_box_east_29b664f93ee940b5_uniq
- ON public.places
- USING btree
- (bounding_box_east);
- -- Index: public.backend_place_bounding_box_north_1388693cd40279f4_uniq
- -- DROP INDEX public.backend_place_bounding_box_north_1388693cd40279f4_uniq;
- CREATE INDEX backend_place_bounding_box_north_1388693cd40279f4_uniq
- ON public.places
- USING btree
- (bounding_box_north);
- -- Index: public.backend_place_bounding_box_south_5a683c209f681fde_uniq
- -- DROP INDEX public.backend_place_bounding_box_south_5a683c209f681fde_uniq;
- CREATE INDEX backend_place_bounding_box_south_5a683c209f681fde_uniq
- ON public.places
- USING btree
- (bounding_box_south);
- -- Index: public.backend_place_bounding_box_west_6fbd144757cbb4eb_uniq
- -- DROP INDEX public.backend_place_bounding_box_west_6fbd144757cbb4eb_uniq;
- CREATE INDEX backend_place_bounding_box_west_6fbd144757cbb4eb_uniq
- ON public.places
- USING btree
- (bounding_box_west);
- -- Index: public.index_places_on_deleted_at
- -- DROP INDEX public.index_places_on_deleted_at;
- CREATE INDEX index_places_on_deleted_at
- ON public.places
- USING btree
- (deleted_at);
- -- Index: public.index_places_on_external_id
- -- DROP INDEX public.index_places_on_external_id;
- CREATE INDEX index_places_on_external_id
- ON public.places
- USING btree
- (external_id COLLATE pg_catalog."default");
- -- Index: public.index_places_on_searchable_and_updated_at
- -- DROP INDEX public.index_places_on_searchable_and_updated_at;
- CREATE INDEX index_places_on_searchable_and_updated_at
- ON public.places
- USING btree
- (searchable, updated_at);
- -- Index: public.index_places_on_updated_at
- -- DROP INDEX public.index_places_on_updated_at;
- CREATE INDEX index_places_on_updated_at
- ON public.places
- USING btree
- (updated_at);
Add Comment
Please, Sign In to add comment