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 1s90Zl-00GjZQ-Tl for pgsql-general@arkaria.postgresql.org; Mon, 20 May 2024 10:49:07 +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 1s90Zl-000eeq-T7 for pgsql-general@arkaria.postgresql.org; Mon, 20 May 2024 10:49:05 +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 1s90Zl-000eeg-Hv for pgsql-general@lists.postgresql.org; Mon, 20 May 2024 10:49:05 +0000 Received: from mail-ua1-x933.google.com ([2607:f8b0:4864:20::933]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1s90Zj-0016rN-53 for pgsql-general@lists.postgresql.org; Mon, 20 May 2024 10:49:04 +0000 Received: by mail-ua1-x933.google.com with SMTP id a1e0cc1a2514c-7f7809ae952so1094904241.0 for ; Mon, 20 May 2024 03:49:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1716202142; x=1716806942; darn=lists.postgresql.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=cx8oPyiSOJgUZfsGXaWq7+xWYvDRqIdnOeN/+HFIr2I=; b=Cxznl9/svUN8jlxbCRJ/DP+nm1RmsLGPfF16yZzcdX9dK/1yoq3Uik/gt3NP0xZbme wF8wV6G38IjghMxs3/It2qCmwVyrfl2/Ro7qZUgWhLI36ImjEEMHU9vM41Wxv9lzGbs6 k4e2BVg76sN8fCr2aRtPJt3aAXDRuBrtcVtpybV+abu7ZuHr440VBG3ITPfnDXMakG4b 148w9IEjQiv/A3rDjogga2OewhQiDgao3xP8t1NBxaVA/qGjH2D2ey12DawxFzkce75r UKyXHJztkWAnB5B6thHwPw0Kz1gRvj38aMVbg/iNIKFBOPOSb/Ckl9Nm59USFGwFfmdN Iw0Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716202142; x=1716806942; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=cx8oPyiSOJgUZfsGXaWq7+xWYvDRqIdnOeN/+HFIr2I=; b=fAe9hYRvl4E4St0BKAqK3Qv0XGe9EGF2fBpAqTVq397skbyuA2bueJhY40NJqiK402 +5picNody4yVoZCdiy4cUJ+x7fnfjpdOztvyw67CV3X5q2KMA66PEaEDsoqQOfOgpp8Z TDaqPUGkWYC6W0N6Nsv70wTRZeHvpmVozGAPvk1XU50bpmd6RC4qs66OcL8uuGEsqelJ /3vpZzl1LnOdEFDhf14XPlWAQP7Eg5GaxiAwWhV9761Af2rivpKeQXUwD6/puIgQq/BI x8vRxe/7Ox92p4fh7/IuuSSeU8vaKm9vnvO6sjOaBr2xlUm2ddO2ZnbC/3OzEvxDyvvn BCKA== X-Gm-Message-State: AOJu0YxrmIaJBg7d31phnnj83gAiBME1X7GUJVlYucIpr1C9Rtf4SsGE DpW6HIrLPGeOt9k0q+gEePliM6cJ8Oyi1fs0jz3jc7rV75gNC5oKAWAuR6quhiruRm9Hyq59sVK gILFNrZvxDXx7NOTEYmH3Bm4p6Gk= X-Google-Smtp-Source: AGHT+IEXb+AJ9qevaiVzTn8RvzzpBLQQGLzsH0kn22WL/ZVzedpsYNYauPPmtpV2oO0rmdBoi/bT2B/vAcVgSLkjejE= X-Received: by 2002:a05:6102:6c1:b0:47c:130d:c928 with SMTP id ada2fe7eead31-48077ddd4afmr30347583137.7.1716202142200; Mon, 20 May 2024 03:49:02 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Kashif Zeeshan Date: Mon, 20 May 2024 15:48:53 +0500 Message-ID: Subject: Re: How to update upper-bound of tstzrange ? To: Laura Smith Cc: postgre Content-Type: multipart/alternative; boundary="0000000000000c7cba0618e0730c" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --0000000000000c7cba0618e0730c Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Try this one. UPDATE foo SET bar_times =3D bar_times + INTERVAL '1 hour' WHERE bar_id =3D 'abc'; Regards Kashif Zeeshan Bitnine Global On Mon, May 20, 2024 at 3:30=E2=80=AFPM Laura Smith < n5d9xq3ti233xiyif2vp@protonmail.ch> wrote: > Could someone kindly help me out with the correct syntax ? > > My first thought was the below but that doesn't work: > > update foo set upper(bar_times)=3Dupper(bar_times)+interval '1' hour wher= e > bar_id=3D'abc'; > ERROR: syntax error at or near "(" > LINE 1: update event_sessions set upper(bar_times)=3Dupper(bar_ti... > > > --0000000000000c7cba0618e0730c Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi

Try this one.=C2=A0

UPDATE foo
SET bar_times =3D bar_times + INTERVAL '1 hour&= #39;
WHERE bar_id =3D 'abc';

Regard= s
Kashif Zeeshan
Bitnine Global

On Mon, May 20, 20= 24 at 3:30=E2=80=AFPM Laura Smith <n5d9xq3ti233xiyif2vp@protonmail.ch> wrote:
Could someone kindly hel= p me out with the correct syntax ?

My first thought was the below but that doesn't work:

update foo set upper(bar_times)=3Dupper(bar_times)+interval '1' hou= r where bar_id=3D'abc';
ERROR:=C2=A0 syntax error at or near "("
LINE 1: update event_sessions set upper(bar_times)=3Dupper(bar_ti...


--0000000000000c7cba0618e0730c--