Files
solace-bg-dubai/backend/drizzle/0001_indexer_state.sql
defiQUG a03417be98
All checks were successful
CI / lint-and-test (push) Successful in 9m52s
chore: consolidate local WIP (repo cleanup 20260707)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-07 09:41:38 -07:00

12 lines
557 B
SQL

CREATE TABLE IF NOT EXISTS "indexer_state" (
"id" uuid PRIMARY KEY DEFAULT gen_random_uuid() NOT NULL,
"chain_id" integer NOT NULL,
"contract_address" text NOT NULL,
"last_block" text NOT NULL,
"updated_at" timestamp DEFAULT now() NOT NULL
);
--> statement-breakpoint
CREATE UNIQUE INDEX IF NOT EXISTS "indexer_state_chain_contract_idx" ON "indexer_state" ("chain_id","contract_address");
--> statement-breakpoint
CREATE UNIQUE INDEX IF NOT EXISTS "transaction_proposals_treasury_proposal_idx" ON "transaction_proposals" ("treasury_id","proposal_id");