userver: samples/postgres_auth/schemas/postgresql/auth/migrations/V001__create_db.sql
Loading...
Searching...
No Matches
samples/postgres_auth/schemas/postgresql/auth/migrations/V001__create_db.sql
1DROP SCHEMA IF EXISTS auth_schema CASCADE;
2
3CREATE SCHEMA IF NOT EXISTS auth_schema;
4
5CREATE TABLE IF NOT EXISTS auth_schema.tokens (
6 token TEXT PRIMARY KEY NOT NULL,
7 user_id INTEGER NOT NULL,
8 scopes TEXT[] NOT NULL,
9 updated TIMESTAMPTZ NOT NULL DEFAULT NOW()
10);