SQL statements error in pgsql 16 but not in pgsql 12

From: Frank Komsic <komsicf(at)shoeicanada(dot)com>
To: "pgsql-sql(at)lists(dot)postgresql(dot)org" <pgsql-sql(at)lists(dot)postgresql(dot)org>
Subject: SQL statements error in pgsql 16 but not in pgsql 12
Date: 2024-07-15 22:57:24
Message-ID: DM4PR05MB92551C285B81BB5FB12F1BC6B3A12@DM4PR05MB9255.namprd05.prod.outlook.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Hi,

I was trying to upgrade our database from version 12.18 to the latest 16.3

After upgrading, the application has reported errors or “junk info” in the sql command line.

Example SQL code:
Message: ERROR: 42601: trailing junk after numeric literal at or near "19749O"
SQL: SELECT bb,mass,classifier,lot
FROM lab.pt_f003_view
WHERE (lot = 19749OR lot= 19750)
ORDER BY lot,bb

The above sql command works in version 12 but does not work in version 16 due to missing space in “WHERE (lot = 19749OR lot= 19750)”

Why did this work before and now it does not work?

Thanks

Frank Komsic

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message David G. Johnston 2024-07-15 23:23:42 Re: SQL statements error in pgsql 16 but not in pgsql 12
Previous Message shammat 2024-07-08 13:44:21 Re: Trick to create alias/mirror table