Extracts the version from a UUID of one of the variants described by RFC 9562.
Signatures & examples
uuid_extract_version ( uuid ) → smallint
Extracts the version from a UUID of one of the variants described by RFC 9562. For other variants, this function returns null. For example, for a UUID generated by gen_random_uuid(), this function will return 4.