Skip to content

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

changed uuid default to gen_random_uuid()

Ollie Halliday8b5ab850d53a
diff --git a/studio/components/interfaces/TableGridEditor/SidePanelEditor/ColumnEditor/ColumnDefaultValue.tsx b/studio/components/interfaces/TableGridEditor/SidePanelEditor/ColumnEditor/ColumnDefaultValue.tsx
index 5959d077c5e..64a6573d927 100644
--- a/studio/components/interfaces/TableGridEditor/SidePanelEditor/ColumnEditor/ColumnDefaultValue.tsx
+++ b/studio/components/interfaces/TableGridEditor/SidePanelEditor/ColumnEditor/ColumnDefaultValue.tsx
@@ -52,7 +52,7 @@ const ColumnDefaultValue: FC<Props> = ({
<InputWithSuggestions
label="Default Value"
layout="vertical"
- description="Can either be a literal or an expression. When using an expression wrap your expression in brackets, e.g. (uuid_generate_v4())"
+ description="Can either be a literal or an expression. When using an expression wrap your expression in brackets, e.g. (gen_random_uuid())"
placeholder={
typeof columnFields.defaultValue === 'string' && columnFields.defaultValue.length === 0
? 'EMPTY'
diff --git a/studio/components/interfaces/TableGridEditor/SidePanelEditor/ColumnEditor/ColumnEditor.constants.ts b/studio/components/interfaces/TableGridEditor/SidePanelEditor/ColumnEditor/ColumnEditor.constants.ts
index fe770d2d081..407f2798911 100644
--- a/studio/components/interfaces/TableGridEditor/SidePanelEditor/ColumnEditor/ColumnEditor.constants.ts
+++ b/studio/components/interfaces/TableGridEditor/SidePanelEditor/ColumnEditor/ColumnEditor.constants.ts
@@ -32,8 +32,8 @@ const defaultTextBasedValues: Suggestion[] = [
export const typeExpressionSuggestions: Dictionary<Suggestion[]> = {
uuid: [
{
- name: 'uuid_generate_v4()',
- value: 'uuid_generate_v4()',
+ name: 'gen_random_uuid()',
+ value: 'gen_random_uuid()',
description: 'Generates a version 4 UUID',
},
],
diff --git a/studio/components/interfaces/TableGridEditor/SidePanelEditor/TableEditor/ColumnManagement.tsx b/studio/components/interfaces/TableGridEditor/SidePanelEditor/TableEditor/ColumnManagement.tsx
index daa71d81168..eac3e0c2540 100644
--- a/studio/components/interfaces/TableGridEditor/SidePanelEditor/TableEditor/ColumnManagement.tsx
+++ b/studio/components/interfaces/TableGridEditor/SidePanelEditor/TableEditor/ColumnManagement.tsx
@@ -241,7 +241,7 @@ const ColumnManagement: FC<Props> = ({
>
<span className="text-xs text-scale-1200">
Can either be a literal or an expression. When using an expression wrap your
- expression in brackets, e.g. (uuid_generate_v4())
+ expression in brackets, e.g. (gen_random_uuid())
</span>
</div>
</Tooltip.Content>