mirror of
https://github.com/QuivrHQ/quivr.git
synced 2024-12-15 01:21:48 +03:00
20 lines
464 B
MySQL
20 lines
464 B
MySQL
|
BEGIN;
|
||
|
|
||
|
-- Create user_identity table if it doesn't exist
|
||
|
CREATE TABLE IF NOT EXISTS prompts (
|
||
|
id UUID DEFAULT uuid_generate_v4() PRIMARY KEY,
|
||
|
title VARCHAR(255),
|
||
|
content TEXT,
|
||
|
status VARCHAR(255) DEFAULT 'private'
|
||
|
);
|
||
|
|
||
|
|
||
|
-- Insert migration record if it doesn't exist
|
||
|
INSERT INTO migrations (name)
|
||
|
SELECT '20230701180101_add_prompts_table'
|
||
|
WHERE NOT EXISTS (
|
||
|
SELECT 1 FROM migrations WHERE name = '20230701180101_add_prompts_table'
|
||
|
);
|
||
|
|
||
|
COMMIT;
|