source: subversion/sites/www.openstreetbrowser.org/src/sql/02_collection.sql @ 29773

Last change on this file since 29773 was 19109, checked in by skunk, 11 years ago

Changes to comply with osmosis-0.31

  • new sql preprocess scripts (osmosis stores 'N', 'W', 'R' as member_type of relations instead of 1, 2, 3)
File size: 800 bytes
Line 
1drop table if exists planet_osm_colls;
2create table planet_osm_colls (
3  id            int4            not null, -- should be def. as primary key
4  type          text            not null,
5  tags_k        text[]          null,
6  tags_v        text[]          null
7);
8
9drop table if exists coll_tags;
10create table coll_tags (
11  coll_id       int4            not null,
12  k             text            not null,
13  v             text            not null
14);
15
16drop table if exists coll_members;
17create table coll_members (
18  coll_id       int4            not null,
19  member_id     int4            not null,
20  member_type   character(1)    not null,
21  member_role   text           
22);
23
24create index planet_osm_colls_id on planet_osm_colls(id);
25create index coll_tags_id on coll_tags(coll_id);
26create index coll_tags_k on coll_tags(k);
27create index coll_members_coll_id on coll_members(coll_id);
28create index coll_members_member_id on coll_members(member_id);
29
30-- member_type:
Note: See TracBrowser for help on using the repository browser.