是否pgadmin 4不支持执行多个选择查询?
我尝试执行此查询
condition1
? result1
: condition2 ? result3 : result4
它只向我展示了一张桌子
答案 0 :(得分:2)
首次查询后您缺少分号错误的SQL语法。
select cust, prod
from sales;
select *
from sales;
仅供参考,在查询工具中执行后不要指望两个单独的结果,您只能从上次查询中获得结果。
更新WITH子句问题。
with Min_cust as (
select cust, max(quant),min(quant) from sales group by cust
),
FinalMin as (
select sales.cust,sales.prod,minium from sales
natural join Min_cust as A where sales.quant=A.min
)
select * from FinalMin;