feature #4: create procedure for citizen

This commit is contained in:
2019-07-26 14:29:48 +02:00
parent 0a92316128
commit fc06965cda
8 changed files with 110 additions and 11 deletions

View File

@@ -0,0 +1,12 @@
create or replace procedure find_citizen_by_id(in id uuid, inout resource json) language plpgsql as
$$
declare
_id alias for id;
begin
select to_json(z) into resource
from citizen as z
where z.id = _id;
end;
$$;
-- drop procedure if exists find_citizen_by_id(uuid, inout json);