[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qexo-general] Re: alternative to 'distinct'
From: |
Per Bothner |
Subject: |
[Qexo-general] Re: alternative to 'distinct' |
Date: |
Wed, 26 Nov 2003 11:20:07 -0800 |
User-agent: |
Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.5) Gecko/20031007 |
bhavin shukla wrote:
I was wonderin if there is any alternative to do 'distinct' in quexo cause i
need to do a query that returns distinct results.
This function is rather inefficient, but it should work with
Kawa 1.7.90:
declare function distinct-values($vals)
{
for $x at $i in $vals
where empty(for $y at $j in $vals
where $j < $i and $x eq $y return $y)
return $x
}
If I have time, I may implement a more efficient distinct-values
for the 1.8 release.
--
--Per Bothner
address@hidden http://per.bothner.com/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Qexo-general] Re: alternative to 'distinct',
Per Bothner <=