adjust for postgres
This commit is contained in:
@ -17,6 +17,7 @@ create table claim_t (
|
||||
id integer primary key not null default nextval('claim_s'),
|
||||
key varchar(64) not null,
|
||||
value varchar(64) not null,
|
||||
application integer not null references application(id),
|
||||
unique (key, value)
|
||||
);
|
||||
|
||||
@ -34,13 +35,16 @@ create table user_application_mapping_t (
|
||||
|
||||
create or replace view claims_for_user_v as
|
||||
select u.id as "user",
|
||||
a.name as application,
|
||||
c.key as key,
|
||||
c.value as value
|
||||
from user_t u,
|
||||
claim_t c,
|
||||
user_claim_mapping_t m
|
||||
user_claim_mapping_t m,
|
||||
application_t a
|
||||
where m.user = u.id and
|
||||
m.claim = c.id;
|
||||
m.claim = c.id and
|
||||
a.id = c.application;
|
||||
|
||||
create or replace view user_application_v as
|
||||
select u.login as login,
|
||||
|
Reference in New Issue
Block a user