Re: Oracle ==> Postgres View - Mailing list pgsql-sql

From David Rowley
Subject Re: Oracle ==> Postgres View
Date
Msg-id CAApHDvo_oS=-roQf29NJ0UQKkYEhSPb3oxqFEz5t-93n0ttb6Q@mail.gmail.com
Whole thread Raw
List pgsql-sql
On Wed, 16 Oct 2024 at 10:31, Sam Stearns <sam.stearns@dat.com> wrote:
>     coalesce(CASE WHEN impact_category='BULK_RATE_REQUEST', 1, -- To handle Portal's category for the old RIP
>        'CONTRACT_BULK_RATE', 1,
>        'SPOT_BULK_RATE', 2,
>        'CONTRACT_HISTORY', 3,
>        'SPOT_HISTORY', 4,
>        'RATE_SUBMISSION', 5,
>        'SPOT_BACKHAUL' THEN  6 END , 0),
>
> Would anyone be able to advise how to correct this for Postgres, please?

Have a look at the syntax of your case statement and check it against [1].

David

[1] https://www.postgresql.org/docs/current/functions-conditional.html



pgsql-sql by date:

Previous
From: "David G. Johnston"
Date:
Subject: Re: invalid reference to FROM-clause entry for table
Next
From: William Alves Da Silva
Date:
Subject: Re: Oracle ==> Postgres View