"Haywood J'Bleauxmie" <hj1(at)fc4(dot)outerscape(dot)net> writes:
> The first SELECT does NOT work in that the distinct() is ignored.
Hard to believe. Would you mind providing a *complete* example?
Queries with no schema or test data are not very helpful.
regards, tom lane