Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hpKx6-0005q1-0n for pgsql-jdbc@arkaria.postgresql.org; Sun, 21 Jul 2019 23:09:12 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hpKx3-0004vD-RS for pgsql-jdbc@arkaria.postgresql.org; Sun, 21 Jul 2019 23:09:09 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hpKx3-0004sN-Eq for pgsql-jdbc@lists.postgresql.org; Sun, 21 Jul 2019 23:09:09 +0000 Received: from mail-pl1-x642.google.com ([2607:f8b0:4864:20::642]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hpKwx-000051-4y for pgsql-jdbc@lists.postgresql.org; Sun, 21 Jul 2019 23:09:09 +0000 Received: by mail-pl1-x642.google.com with SMTP id ay6so18266359plb.9 for ; Sun, 21 Jul 2019 16:09:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:mime-version:subject:date:references:to:in-reply-to:message-id; bh=MybdqHnhAE+AwDVgYgP5AYjSdLGgelb6/VYmgzHdx4Y=; b=mCYAZf+BrqQO9X0uV5WpLN8m22mzpBx7SPJpus2vAP+/4d5AcamcjWUhPENU99TWIv +2NhBNUty62Flxj9B+KkB+c6YUrKJuoVibdCntr41W/jl/Duy4dZXYZhhJCBgGlr7y0f 923amPaRYZ2cVvGK7+JX9EYKl86n9tEtm7mF8g3b9I8UDKv6Z8iJ2v9t87aJ0hsct/Mq JGKtV9/0eBbxfWldhhmUgQ/B8J70cQQlQ4JxlZfQZ1EntjphhYZtE25BEnFfVeFnfaiE YafWpcca8canFSsnjZ7wderLv8g6BMCMx7+nK2nX9eSqOtAY4igZdujsq7uRNI+8E2ZT 12Xg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:subject:date:references:to :in-reply-to:message-id; bh=MybdqHnhAE+AwDVgYgP5AYjSdLGgelb6/VYmgzHdx4Y=; b=SlEicdhVny98gbWp87mjE2HLpjdqq/BU0Ku+BuJ0cT3seTPHdjeXjx3iQdZVPiDshu 1wSBCQHe3vRXFSskPhb+4I/UaJuJr1uIItH1okXVA82krX0BJVWa7WwQVYwPWnNWp5gH 7L60HBjuGv+nx283j6M0TUH1E5UB1NzfYWkcYimftIuX0x7NIGc/0pu38Dt+oJq34GPZ dvzmWhe+sQfGGSWrbsk2NwadflBDmHwu6nVAQ5kPzfKZnow6ygCliUvfqJBiAM/mDGqR 23TVElx6vLTS8T1p37Z+xQxuYhdVTkrbbSYMskYxHGiRPqtAfBQWYwwKjn0vFGYN0X+3 oopA== X-Gm-Message-State: APjAAAVgLaXVKBYoExF/f74c/BpTBi2wnidCRHCtqmR1ep/ju8tFG5GG eSG6+deP8aIhm5Ozc2jabpilwpisKo8= X-Google-Smtp-Source: APXvYqzuaEkjIEG/6LrAxAOYw3jyt69Bq/zmYHHIp4PA+YUr8ALlaUOkCKCMQHzSOV7MgZSgZ41/3A== X-Received: by 2002:a17:902:1102:: with SMTP id d2mr71994147pla.149.1563750539704; Sun, 21 Jul 2019 16:08:59 -0700 (PDT) Received: from [192.168.0.167] (c-76-22-40-96.hsd1.wa.comcast.net. [76.22.40.96]) by smtp.gmail.com with ESMTPSA id 124sm39358481pfw.142.2019.07.21.16.08.59 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 21 Jul 2019 16:08:59 -0700 (PDT) From: Basil Bourque X-Google-Original-From: Basil Bourque Content-Type: multipart/alternative; boundary="Apple-Mail=_F3351A3B-4E4A-43D8-82D5-C5CAE39F826E" Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Subject: Re: (How to) Make SQLData of UUID? Date: Sun, 21 Jul 2019 16:08:58 -0700 References: To: pgsql-jdbc@lists.postgresql.org In-Reply-To: Message-Id: X-Mailer: Apple Mail (2.3445.104.11) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --Apple-Mail=_F3351A3B-4E4A-43D8-82D5-C5CAE39F826E Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > Any hints please? >=20 Does this Answer by Gopinagh.R on Stack Overflow help? https://stackoverflow.com/a/14197445/642706 = CREATE OR REPLACE FUNCTION generatesurrogat() RETURNS uuid AS $BODY$DECLARE=20 uid UUID; BEGIN uid:=3D(select uuid_generate_v1()); RAISE NOTICE 'My UUID is %',uid; return uid; END$BODY$ LANGUAGE plpgsql VOLATILE COST 100; =E2=80=94BB= --Apple-Mail=_F3351A3B-4E4A-43D8-82D5-C5CAE39F826E Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8
Any hints please?


Does this Answer by Gopinagh.R on Stack Overflow = help?


CREATE =
OR REPLACE FUNCTION =
generatesurrogat() =
RETURNS uuid AS
$BODY$DECLARE=20
uid UUID;
BEGIN
uid:=3D(select =
uuid_generate_v1());
RAISE NOTICE 'My UUID is %',uid;
return =
uid;
END$BODY$
LANGUAGE plpgsql VOLATILE
COST 100;


=E2=80=94BB
= --Apple-Mail=_F3351A3B-4E4A-43D8-82D5-C5CAE39F826E--