Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

feat(sql-editor): add hint to ai prompt to prefer timestamp with time zone

Greg Richardson539a4d6f6cd0
diff --git a/studio/pages/api/ai/sql.ts b/studio/pages/api/ai/sql.ts
index de0dc2fd787..72d26e2fc87 100644
--- a/studio/pages/api/ai/sql.ts
+++ b/studio/pages/api/ai/sql.ts
@@ -20,8 +20,8 @@ const generateSqlSchema = SchemaBuilder.emptySchema()
The generated SQL.
- For primary keys, always use "id bigint primary key generated always as identity" (not serial)
- Prefer creating foreign key references in the create statement
- - Prefer text over varchar
- - Prefer timestamp over date
+ - Prefer 'text' over 'varchar'
+ - Prefer 'timestamp with time zone' over 'date'
- Use vector(384) data type for any embedding/vector related query
`,
})