Hi,
Anyone knows if I can use column aliases in having condition?
Something like this.
pgdb=# select sum(c_acctbal) as p from customer having p >
1000;
select sum(c_acctbal) as p from customer having p >
1000;
ERROR: column "p" does not
exist
LINE 1: select sum(c_acctbal) as p from customer
Hi,
I am trying to use psql \set and \echo commands to set some internal
variables.
My variable starts with single quote and ends with single quote.
That is actual value of the variable.
Eg.
set cur_db 'pgdb'
\echo :cur_db
--I am expecting here 'pgdb' but psql shows pgdb
As mentioned above, I am
Hi,
I am trying to use psql \set and \echo commands to set some internal
variables.
My variable starts with single quote and ends with single quote.
That is actual value of the variable.
Eg.
set cur_db 'pgdb'
\echo :cur_db
--I am expecting here 'pgdb' but psql shows pgdb
As mentioned above, I am