4 ms·
This article is a little old. First thing that isn't correct or changed since this was written: > There don't seem to be any existing built-in or extension fu
by sbuttgereit 3y ago
This article is a little old.
First thing that isn't correct or changed since this was written:
> There don't seem to be any existing built-in or extension functions that support generating UUIDv7s in PostgreSQL. To generate a UUIDv7, the function below could be tweaked in order to support the correct formatting.
This is the extension I use until UUIDv7 native support lands in PostgreSQL https://github.com/fboulnois/pg_uuidv7 https://github.com/fboulnois/pg_uuidv7. As for native support, it's definitely underway, though it seems to have a few issues keeping up with the version 17 target release: https://commitfest.postgresql.org/47/4388/ https://commitfest.postgresql.org/47/4388/
- nicwolff 3y agoIt was already out of date when published in Feb 2022: > PostgreSQL has built in support for UUIDv4 through the pgcrypto or the uuid-ossp extensions. PostgreSQL hasn't needed an extension to generate UUIDv4 since v13 which was released in Sep 2020.