mirror of
https://github.com/bitbaum/botsmann.git
synced 2026-12-04 04:47:45 +01:00
- Add @~/.claude/CLAUDE.md import for global engineering standards - Update Last Updated date to 2026-01-23 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
18 lines
708 B
SQL
18 lines
708 B
SQL
-- Add status and tracking columns to documents table
|
|
|
|
ALTER TABLE documents
|
|
ADD COLUMN IF NOT EXISTS status TEXT DEFAULT 'pending' CHECK (status IN ('pending', 'processing', 'ready', 'error')),
|
|
ADD COLUMN IF NOT EXISTS error_message TEXT,
|
|
ADD COLUMN IF NOT EXISTS chunk_count INTEGER DEFAULT 0,
|
|
ADD COLUMN IF NOT EXISTS updated_at TIMESTAMPTZ DEFAULT NOW();
|
|
|
|
-- Add update trigger for documents
|
|
DROP TRIGGER IF EXISTS update_documents_updated_at ON documents;
|
|
CREATE TRIGGER update_documents_updated_at
|
|
BEFORE UPDATE ON documents
|
|
FOR EACH ROW
|
|
EXECUTE FUNCTION update_updated_at();
|
|
|
|
-- Create storage bucket for documents (run via Supabase dashboard or API)
|
|
-- Storage policy will be set up separately
|