Migration

/queries/schema/createDatabase.sql (286 B)

1
2
3
4
5
6
7
8
-- $PF_GENERATE_ONCE$
-- {% func CreateDatabase() %}
create role "{{{ .Key }}}" with login password '{{{ .Key }}}';

create database "{{{ .Key }}}";
alter database "{{{ .Key }}}" set timezone to 'utc';
grant all privileges on database "{{{ .Key }}}" to "{{{ .Key }}}";
-- {% endfunc %}