assuming-long-roleidnames + object-uuid-based-rolenames #139
@ -251,9 +251,14 @@ begin
|
|||||||
execute sql into uuid;
|
execute sql into uuid;
|
||||||
exception
|
exception
|
||||||
when others then
|
when others then
|
||||||
raise exception 'function %_uuid_by_id_name(...) not found, add identity view support for table %', objectTable, objectTable;
|
raise exception 'function %_uuid_by_id_name(''%'') failed: %, SQLSTATE: %. If it could not be found, add identity view support to %\nSQL:%',
|
||||||
|
objectTable, objectIdName, SQLERRM, SQLSTATE, objectTable, sql;
|
||||||
end;
|
end;
|
||||||
|
if uuid is null then
|
||||||
|
raise exception 'SQL returned null: %', sql;
|
||||||
|
else
|
||||||
return uuid;
|
return uuid;
|
||||||
|
end if;
|
||||||
end ; $$;
|
end ; $$;
|
||||||
|
|
||||||
create or replace function rbac.findIdNameByObjectUuid(objectTable varchar, objectUuid uuid)
|
create or replace function rbac.findIdNameByObjectUuid(objectTable varchar, objectUuid uuid)
|
||||||
@ -270,7 +275,8 @@ begin
|
|||||||
execute sql into idName;
|
execute sql into idName;
|
||||||
exception
|
exception
|
||||||
when others then
|
when others then
|
||||||
raise exception 'function %_id_name_by_uuid(...) not found, add identity view support for table %', objectTable, objectTable;
|
raise exception 'function %_id_name_by_uuid(''%'') failed: %, SQLSTATE: %. If it could not be found, add identity view support to %',
|
||||||
|
objectTable, objectUuid, SQLERRM, SQLSTATE, objectTable;
|
||||||
end;
|
end;
|
||||||
return idName;
|
return idName;
|
||||||
end ; $$;
|
end ; $$;
|
||||||
|
Loading…
Reference in New Issue
Block a user