Created
October 17, 2013 12:34
-
-
Save be9/7024131 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| dp_development=# \d transport_stations | |
| Таблица "public.transport_stations" | |
| Колонка | Тип | Модификаторы | |
| ------------+-----------------------------+----------------------------------------------------------------- | |
| id | integer | NOT NULL DEFAULT nextval('transport_stations_id_seq'::regclass) | |
| name | character varying(255) | | |
| lng | double precision | | |
| lat | double precision | | |
| code | character varying(255) | | |
| details | character varying(255) | | |
| kind | character varying(255) | | |
| created_at | timestamp without time zone | NOT NULL | |
| updated_at | timestamp without time zone | NOT NULL | |
| full_name | character varying(255) | | |
| slug | character varying(255) | | |
| Индексы: | |
| "transport_stations_pkey" PRIMARY KEY, btree (id) | |
| "index_transport_stations_on_slug" UNIQUE, btree (slug) | |
| "index_transport_stations_on_full_name_trgm_gist" gist (full_name gist_trgm_ops) | |
| "index_transport_stations_on_name_trgm_gist" gist (name gist_trgm_ops) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| dp_development=# EXPLAIN SELECT * FROM transport_stations WHERE NAME ILIKE '%harbour%'; | |
| QUERY PLAN | |
| ---------------------------------------------------------------------------------------------------------- | |
| Bitmap Heap Scan on transport_stations (cost=4.50..60.31 rows=32 width=115) | |
| Recheck Cond: ((name)::text ~~* '%harbour%'::text) | |
| -> Bitmap Index Scan on index_transport_stations_on_name_trgm_gist (cost=0.00..4.49 rows=32 width=0) | |
| Index Cond: ((name)::text ~~* '%harbour%'::text) | |
| (4 строки) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment