GIN индексы это скорость )
теперь запросы за 200ms делаются
select * from "db1" ps where "Url" like '%profilesettings%'
Bitmap Heap Scan on "db1 " ps (cost=740.34..12974.90 rows=3141 width=439) (actual time=139.469..139.912 rows=220 loops=1)
Recheck Cond: ("Url" ~~ '%profilesettings%'::text)
Rows Removed by Index Recheck: 19
Heap Blocks: exact=238
-> Bitmap Index Scan on db_url_trgm_idx (cost=0.00..739.56 rows=3141 width=0) (actual time=139.435..139.436 rows=239 loops=1)
Index Cond: ("Url" ~~ '%profilesettings%'::text)
Planning Time: 0.418 ms
Execution Time: 139.946 ms