Index: LICENSE ================================================================== --- LICENSE +++ LICENSE @@ -1,7 +1,6 @@ -Copyright (c) 2006-2010 - Volodymyr Kostyrko +Copyright (c) 2006-2010 Volodymyr Kostyrko Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell Index: database.sql ================================================================== --- database.sql +++ database.sql @@ -23,18 +23,22 @@ from_time time without time zone DEFAULT '00:00:00'::time without time zone NOT NULL, to_time time without time zone DEFAULT '23:59:59'::time without time zone NOT NULL, tag text[] NOT NULL ); +create index rules_tag_g on rules using gin (tag); + -- table to hold tag - site links CREATE TABLE urls ( date_added timestamp without time zone DEFAULT ('now'::text)::timestamp(0) without time zone NOT NULL, site text[] NOT NULL, tag text[] NOT NULL, regexp text ); +create index urls_tag_g on urls using gin (tag); +create index urls_site_g on urls using gin (site); create unique index urls_rst on urls (regexp, usort(site), usort(tag)); -- rule to join all tables into one to simplify access -- automaticall uses current day and time data create view site_rule as