"Peter Galbavy" <peter.galbavy@knowtion.net> writes:
> Not sure - what I want is only one row per real row but ordered as per the
> constants. When you say duplicate-row-elimination do you mean including the
> 'constant' weighting,
Yes, UNION would consider all columns in deciding if two rows are dups.
> What I mean is when an image row has both 'eat static' in the caption and as
> a keyword, I want it returned only once...
I think your query might fail on that requirement regardless, no? At
least I missed how you'd prevent it.
regards, tom lane