Re: Pgcrypto (PostgreSQL 10) on Debain 9? - Mailing list pgsql-general

From Michael Paquier
Subject Re: Pgcrypto (PostgreSQL 10) on Debain 9?
Date
Msg-id 20180207050632.GA1753@paquier.xyz
Whole thread Raw
In response to Re: Pgcrypto (PostgreSQL 10) on Debain 9?  (Raymond O'Donnell <rod@iol.ie>)
List pgsql-general
On Tue, Feb 06, 2018 at 03:58:14PM +0000, Raymond O'Donnell wrote:
> On 06/02/18 13:25, Thiemo Kellner, NHC Barhufpflege wrote:
>> But why do I get following error?
>> ERROR: function gen_random_uuid() does not exist.
>> create table ENTITY (ID uuid not null default gen_random_uuid());
>
> Only a guess, but maybe you need to install the extension first? -
>
>    create extension <whatever>;

For gen_random_uuid(), you need to enable pgcrypto:
create extension pgcrypto;
For a couple of other UUID-related functions, you need to enable
uuid-ossp:
create extension "uuid-ossp";
--
Michael

Attachment

pgsql-general by date:

Previous
From: Jeremy Finzel
Date:
Subject: Re: Alter table set logged hanging after writing out all WAL
Next
From: Shreeyansh Dba
Date:
Subject: Re: Fwd: postgres instalation