Something went wrong. Try again.
Our Personal Data Server from scratch! forked from tranquil.farm/tranquil-pds
Something went wrong. Try again.
803 B · 23 lines
SQL
at main
123456789101112131415161718192021222324CREATE INDEX IF NOT EXISTS idx_session_tokens_did_created_atON session_tokens(did, created_at DESC);
CREATE INDEX IF NOT EXISTS idx_oauth_token_did_expires_atON oauth_token(did, expires_at DESC);
CREATE INDEX IF NOT EXISTS idx_oauth_token_did_created_atON oauth_token(did, created_at DESC);
CREATE INDEX IF NOT EXISTS idx_session_tokens_did_refresh_expiresON session_tokens(did, refresh_expires_at DESC);
CREATE INDEX IF NOT EXISTS idx_app_passwords_user_createdON app_passwords(user_id, created_at DESC);
CREATE INDEX IF NOT EXISTS idx_records_repo_collection_rkeyON records(repo_id, collection, rkey);
CREATE INDEX IF NOT EXISTS idx_passkeys_did_createdON passkeys(did, created_at DESC);
CREATE INDEX IF NOT EXISTS idx_backup_codes_did_unusedON backup_codes(did) WHERE used_at IS NULL;