The PostgreSQL operation INTERSECT ALL
does not seem to work. What am I missing?
The following query returns just one row containing the value two, but I am expecting two with the value as I am using intersect all
.
(
(select 1 as z)
union all
(select 2 as z)
union all
(select 2 as z)
)
intersect all
(select 2 as z)
Does anyone have a guess?