Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sGqF2-000BdR-72 for pgsql-general@arkaria.postgresql.org; Tue, 11 Jun 2024 01:24:04 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1sGqF0-000kYZ-NK for pgsql-general@arkaria.postgresql.org; Tue, 11 Jun 2024 01:24:03 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sGqF0-000kYP-9M for pgsql-general@lists.postgresql.org; Tue, 11 Jun 2024 01:24:03 +0000 Received: from mail-oo1-xc33.google.com ([2607:f8b0:4864:20::c33]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1sGqEy-000iWP-KM for pgsql-general@lists.postgresql.org; Tue, 11 Jun 2024 01:24:01 +0000 Received: by mail-oo1-xc33.google.com with SMTP id 006d021491bc7-5baeab9fd60so913987eaf.2 for ; Mon, 10 Jun 2024 18:24:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1718069040; x=1718673840; darn=lists.postgresql.org; h=cc:to:subject:message-id:date:from:references:in-reply-to :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=687VaC5s6kjPAyDza13vHDbnizJKb71ykdgkg8sfatA=; b=KoUGNnCZsAn92JZeup/8HumKSmaQJlXyYXZ1P658GTlqIASdq0HLXZffWKnI2zDVuk tzz99PMmOKn8Ve7/qgQPE/dKzi2xn8kw2UwHyK/ozdrs3MoRERM4PUnyH8OmDN2qr5Cc gE0FTxuERPKA9/WFJZjlTCgnH0tSQY+sJmiUjgws7E5SOiqQlTOI1phc1kRCiQTYlujv Ryc9h7XwJ4aCCKTPyFMMivqWZkMFpLbeivEOnsW9Qgn9xJRK/ebYB8TVUm+FY6GcLlrU WpV0whDpsDz4W4Q29fR+gbuV7LujGKoMSrkbR2w3Kvd2Ma36O+vDeQCPH6YEFVJlQsXb /YHw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718069040; x=1718673840; h=cc:to:subject:message-id:date:from:references:in-reply-to :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=687VaC5s6kjPAyDza13vHDbnizJKb71ykdgkg8sfatA=; b=lDUrKd3B2YgVG0G7Nro+g8klB5D7tYTTOP5LCKrbDm3rFO7zBfxORap2yEqvS/vMHd 7f0+Rv5CWn7IftfTVKVt9xjJBvp6hYKBr/Lq/vMRel44ivAhAAoLxBh0u4AekXfkCLgk c+gW9izH8/MRib8CSj1XuG75aWWf+Ag+CJesSJGdpxMPaKy33r4rvZ7ro530ixlH7IKF +77UM0VWVI487QCepOVfr8JQdcvN2MBLwqOtlOsPuokpXyYXrNpm/e4j372Ry9GxAVE6 T+C8MHhvkMuDIFqfAq7yYkkOmRxzUFwA55wOrvnVbrVsKqqA+BLa4mvAhAql6RIYBzbt NVeg== X-Gm-Message-State: AOJu0YyyM4EHQnj9Kokf9ywec9rr/X+fAp6GUJvwwPsrA3zfEFjSc2XY zqr2ci/pRM9jcyfNwRgz9niu9wq38UFDQGyk3S+7Qadbxo0PvgoQUzwrwfAfKdU0IIHYO/78Xxj BKf+oXs6M9+023bpxbgURXmFhDE8= X-Google-Smtp-Source: AGHT+IFTd1kkmqu7u30Lbf02sjNAxGmoaMaPFS0mlZA7LHGbuBPoicIiPvOBqy0PVdIxqA4LogBMo+4QwjD8qhEu5WE= X-Received: by 2002:a05:6820:1c85:b0:5ba:ccd2:2bb0 with SMTP id 006d021491bc7-5baccd22edamr9184322eaf.1.1718069039671; Mon, 10 Jun 2024 18:23:59 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a05:6802:387:b0:530:392d:d678 with HTTP; Mon, 10 Jun 2024 18:23:58 -0700 (PDT) In-Reply-To: References: <35fd10ab-5f7f-7a57-9cc5-c03d81476d13@appl-ecosys.com> From: "David G. Johnston" Date: Mon, 10 Jun 2024 18:23:58 -0700 Message-ID: Subject: Re: Gaps in PK sequence numbers [RESOLVED] To: Rich Shepard Cc: "pgsql-general@lists.postgresql.org" Content-Type: multipart/alternative; boundary="000000000000cf31ba061a931ec8" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --000000000000cf31ba061a931ec8 Content-Type: text/plain; charset="UTF-8" On Monday, June 10, 2024, Rich Shepard wrote: > > Is there a way to reset the sequence to the maximum > number +1? I don't recall seeing this in the postgres docs but will look > again. > https://www.postgresql.org/docs/current/functions-sequence.html setval The bigint argument can be computed from a query. David J. --000000000000cf31ba061a931ec8 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Monday, June 10, 2024, Rich Shepard <rshepard@appl-ecosys.com> wrote:

Is there a way to reset the sequence to the maximum
number +1? I don't recall seeing this in the postgres docs but will loo= k
again.


setval
=
The bigint argument can be computed from a query.
=
David J.
--000000000000cf31ba061a931ec8--