Re: - operator overloading not giving expected result

2022-07-11 Thread Rajesh S
Hi All, Thank you for your valuable comments and suggestions.  As it was pointed out we are using EDB Postgres and the language was mentioned as 'edbspl'.  We made to work by setting the search_path variable as follows: set search_path="$user", public, pg_catalog And also changed the Operato

Re: - operator overloading not giving expected result

2022-07-08 Thread Ravi Krishna
LANGUAGE 'edbspl' This is the root cause of your issue. You are not using PGSQL, but EDB version of it which is compatible with Oracle PL/SQL.

Re: - operator overloading not giving expected result

2022-07-08 Thread Tom Lane
Christoph Moench-Tegeder writes: > ## Rajesh S (rajes...@fincuro.com): >> We are migrating our database from Oracle to Postgresql.  In oracle we >> have used this syntax "SELECT ('1999-12-30'::DATE) - >> ('1999-12-11'::DATE)" to get difference between two dates as a integer >> output (ex: 19). 

Re: - operator overloading not giving expected result

2022-07-08 Thread Christoph Moench-Tegeder
## Rajesh S (rajes...@fincuro.com): > We are migrating our database from Oracle to Postgresql.  In oracle we > have used this syntax "SELECT ('1999-12-30'::DATE) - > ('1999-12-11'::DATE)" to get difference between two dates as a integer > output (ex: 19).  But in Postgres the same query returns

Re: - operator overloading not giving expected result

2022-07-08 Thread Francisco Olarte
Hi Rajesh: On Fri, 8 Jul 2022 at 12:36, Rajesh S wrote: > We are migrating our database from Oracle to Postgresql. In oracle we have > used this syntax "SELECT ('1999-12-30'::DATE) - ('1999-12-11'::DATE)" to get > difference between two dates as a integer output (ex: 19). But in Postgres > t

Re: - operator overloading not giving expected result

2022-07-08 Thread Peter J. Holzer
On 2022-07-05 13:52:32 +0530, Rajesh S wrote: > We are migrating our database from Oracle to Postgresql.  In oracle we have > used this syntax "SELECT ('1999-12-30'::DATE) - ('1999-12-11'::DATE)" to get > difference between two dates as a integer output (ex: 19).  But in Postgres > the > same quer