aboutsummaryrefslogtreecommitdiff
path: root/sources/db
diff options
context:
space:
mode:
authorJochen Topf <jochen@topf.org>2015-03-06 11:16:09 +0100
committerJochen Topf <jochen@topf.org>2015-03-06 11:16:09 +0100
commit63fc20d8d0e2acdf35e98bfd0829b52c8cc91306 (patch)
treec7d7c55852508d3d960e29c61ef009a75c6b3545 /sources/db
parent520653a8706185f4c182f78d6f373c91a40eab54 (diff)
downloadtaginfo-63fc20d8d0e2acdf35e98bfd0829b52c8cc91306.tar
taginfo-63fc20d8d0e2acdf35e98bfd0829b52c8cc91306.tar.gz
Remove deprecated table "selected_tags".
Diffstat (limited to 'sources/db')
-rw-r--r--sources/db/post.sql18
-rw-r--r--sources/db/pre.sql12
2 files changed, 0 insertions, 30 deletions
diff --git a/sources/db/post.sql b/sources/db/post.sql
index 3e5b931..ad58ef6 100644
--- a/sources/db/post.sql
+++ b/sources/db/post.sql
@@ -61,24 +61,6 @@ CREATE UNIQUE INDEX relation_types_rtype_idx ON relation_types (rtype);
CREATE INDEX relation_roles_rtype_idx ON relation_roles (rtype);
-- ============================================================================
--- deprecated: can be removed soon
-
-INSERT INTO selected_tags (skey, svalue)
- SELECT key1, value1 FROM tag_combinations WHERE value1 != ''
- UNION
- SELECT key2, value2 FROM tag_combinations WHERE value2 != '';
-
-UPDATE selected_tags SET
- count_all = (SELECT t.count_all FROM tags t WHERE t.key=skey AND t.value=svalue),
- count_nodes = (SELECT t.count_nodes FROM tags t WHERE t.key=skey AND t.value=svalue),
- count_ways = (SELECT t.count_ways FROM tags t WHERE t.key=skey AND t.value=svalue),
- count_relations = (SELECT t.count_relations FROM tags t WHERE t.key=skey AND t.value=svalue);
-
-ANALYZE selected_tags;
-
-CREATE UNIQUE INDEX selected_tags_key_value_idx ON selected_tags (skey, svalue);
-
--- ============================================================================
INSERT INTO stats (key, value) SELECT 'num_keys', count(*) FROM keys;
INSERT INTO stats (key, value) SELECT 'num_keys_on_nodes', count(*) FROM keys WHERE count_nodes > 0;
diff --git a/sources/db/pre.sql b/sources/db/pre.sql
index 586fe6c..9ee7126 100644
--- a/sources/db/pre.sql
+++ b/sources/db/pre.sql
@@ -140,15 +140,3 @@ CREATE TABLE prevalent_roles (
fraction REAL
);
--- deprecated: can be removed soon
-DROP TABLE IF EXISTS selected_tags;
-CREATE TABLE selected_tags (
- skey VARCHAR,
- svalue VARCHAR,
- count_all INTEGER DEFAULT 0,
- count_nodes INTEGER DEFAULT 0,
- count_ways INTEGER DEFAULT 0,
- count_relations INTEGER DEFAULT 0,
- in_wiki INTEGER
-);
-