public inbox for [email protected]  
help / color / mirror / Atom feed
From: Han Tang <[email protected]>
To: [email protected]
Subject: Postgresql range_agg() Return empty list
Date: Wed, 10 Jul 2024 18:37:11 -0700
Message-ID: <CAAqOU0s08dTFu0tQgEg=q+ifeU4aSYwxCG=ae229PrwwAea2mA@mail.gmail.com> (raw)

Hi

Hope you are doing well!

I am using range_agg() function, it works fine with original table value

Query Result <https://i.sstatic.net/CbOkuvXr.png;

But when I try to do some update for range value, it will give back an
empty list

Select range_agg(b.r)From (
  Select int8range(lower(bin_range)+1, upper(bin_range)+5) as r
  From bin_data) as b;

Query Result <https://i.sstatic.net/19uJeuS3.png;

I test with the same query in fiddle but no issue there

https://dbfiddle.uk/1MRn8hn6

All these query are running on pgAdmin4, wondering why it happens

Thanks
Han


Attachments:

  [image/png] Screenshot 2024-07-10 at 5.43.44 PM.png (72.3K, 3-Screenshot%202024-07-10%20at%205.43.44%E2%80%AFPM.png)
  download | view image

  [image/png] Screenshot 2024-07-10 at 5.50.40 PM.png (87.4K, 4-Screenshot%202024-07-10%20at%205.50.40%E2%80%AFPM.png)
  download | view image

view thread (2+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected]
  Subject: Re: Postgresql range_agg() Return empty list
  In-Reply-To: <CAAqOU0s08dTFu0tQgEg=q+ifeU4aSYwxCG=ae229PrwwAea2mA@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox