pg.ddx.io pgsql-bugs@postgresql.org mailing list archive
help / color / mirror / Atom feedBUG #18924: The "ERROR: integer out of range" should be more detailed
2+ messages / 2 participants
[nested] [flat]
* BUG #18924: The "ERROR: integer out of range" should be more detailed
@ 2025-05-12 08:05 PG Bug reporting form <noreply@postgresql.org>
0 siblings, 1 reply; 2+ messages in thread
From: PG Bug reporting form @ 2025-05-12 08:05 UTC (permalink / raw)
To: pgsql-bugs@lists.postgresql.org; +Cc: sysgeo@gmail.com
The following bug has been logged on the website:
Bug reference: 18924
Logged by: Adrien Ducos
Email address: sysgeo@gmail.com
PostgreSQL version: 17.4
Operating system: aarch64-unknown-linux-gnu (AWS RDS)
Description:
I am on postgresql version 17.4
select version();
--PostgreSQL 17.4 on aarch64-unknown-linux-gnu, compiled by gcc (GCC)
12.4.0, 64-bit
This is a simple query to reproduce:
with test_cte as (
select
5000000000.25 as very_big_number,
50000000.86 as big_number,
50000.59 as some_number,
500.56 as small_number
)
select
very_big_number::integer as very_big_integer,
big_number::integer as big_integer,
some_number::integer as some_integer,
small_number::integer as small_integer
from test_cte;
--ERROR: integer out of range
The problem here is not that the integer is out of range (5 billion is out
of range for the integer type). The problem is that the error message does
not tell me where the error is in the query.
I would like some context to find the error, that it happens on line ...
"very_big_number::integer" is out of range.
The problem is that I manage sql queries with thousands of lines that runs
during 2 hours to create my models and if I want to find the error, I have
to simplifiy and run my query 10-20 times to finaly find where the error is.
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: BUG #18924: The "ERROR: integer out of range" should be more detailed
@ 2025-05-12 12:36 David G. Johnston <david.g.johnston@gmail.com>
parent: PG Bug reporting form <noreply@postgresql.org>
0 siblings, 0 replies; 2+ messages in thread
From: David G. Johnston @ 2025-05-12 12:36 UTC (permalink / raw)
To: sysgeo@gmail.com <sysgeo@gmail.com>; pgsql-bugs@lists.postgresql.org <pgsql-bugs@lists.postgresql.org>
On Monday, May 12, 2025, PG Bug reporting form <noreply@postgresql.org>
wrote:
> The following bug has been logged on the website:
>
> Bug reference: 18924
> Logged by: Adrien Ducos
> Email address: sysgeo@gmail.com
> PostgreSQL version: 17.4
> Operating system: aarch64-unknown-linux-gnu (AWS RDS)
> Description:
>
> --ERROR: integer out of range
> The problem here is not that the integer is out of range (5 billion is out
> of range for the integer type). The problem is that the error message does
> not tell me where the error is in the query.
>
>
This is a known limitation that is looking for someone(s) to volunteer to
do some hard design and development work to overcome.
Some existing thoughts on the topic can be found by searching these mailing
lists.
David J.
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2025-05-12 12:36 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2025-05-12 08:05 BUG #18924: The "ERROR: integer out of range" should be more detailed PG Bug reporting form <noreply@postgresql.org>
2025-05-12 12:36 ` David G. Johnston <david.g.johnston@gmail.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox