comparison artifact-database/src/main/resources/sql/org-postgresql-driver.properties @ 215:a9c8fa38ba03

Added new collection specific sql statements. artifacts/trunk@1554 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Thu, 24 Mar 2011 11:28:26 +0000
parents 199f0e553e3a
children 2d90d5cfe8f9
comparison
equal deleted inserted replaced
214:fc435da7f471 215:a9c8fa38ba03
27 27
28 # USERS 28 # USERS
29 29
30 users.id.nextval=SELECT NEXTVAL('USERS_ID_SEQ') 30 users.id.nextval=SELECT NEXTVAL('USERS_ID_SEQ')
31 31
32 users.insert=INSERT INTO users (id, gid, name, role) VALUES (?, ?, ?, ?) 32 users.insert=INSERT INTO users (id, gid, name, role) VALUES (?, ?::uuid, ?, ?)
33 33
34 users.select.id.by.gid=SELECT id FROM users WHERE gid = ?::uuid 34 users.select.id.by.gid=SELECT id FROM users WHERE gid = ?::uuid
35 users.select.gid=SELECT id, name, role FROM users WHERE gid = ?::uuid 35 users.select.gid=SELECT id, name, role FROM users WHERE gid = ?::uuid
36 36
37 users.delete.id=DELETE FROM users WHERE id = ? 37 users.delete.id=DELETE FROM users WHERE id = ?
117 117
118 collections.select.all= \ 118 collections.select.all= \
119 SELECT c.gid, c.name, c.creation, u.gid FROM \ 119 SELECT c.gid, c.name, c.creation, u.gid FROM \
120 collections c LEFT OUTER JOIN users u ON c.owner_id = u.id 120 collections c LEFT OUTER JOIN users u ON c.owner_id = u.id
121 121
122 collections.select.by.gid= \
123 SELECT id, name, owner_id, creation, last_access, attribute \
124 FROM collections WHERE gid = ?
125
122 users.collections=SELECT collection_id, gid, name FROM collections WHERE owner_id = ? 126 users.collections=SELECT collection_id, gid, name FROM collections WHERE owner_id = ?
123 users.collection.ids=SELECT collection_id FROM collections WHERE owner_id = ? 127 users.collection.ids=SELECT collection_id FROM collections WHERE owner_id = ?
124 128
125 artifacts.in.one.collection.only=\ 129 artifacts.in.one.collection.only=\
126 SELECT artifact_id FROM collection_items\ 130 SELECT artifact_id FROM collection_items\

http://dive4elements.wald.intevation.org