[daisy] SELECT DISTINCT

Bruno Dumon bruno at outerthought.org
Fri Nov 24 03:17:27 CST 2006


On Thu, 2006-11-23 at 15:13 +0100, Carlos Palol wrote:
> Hi,
> Is there any way to do a distinct select to the repository?
> 

Not really like the way one would do in SQL.

Daisy queries are quite different from SQL queries in that they always
search for documents, and each row of the resultset corresponds to a
document (in contrast to simply a table of values). Each document
appears at most once in the resultset, so it contains only distinct
documents.

Given this, it is not really possible to do distinct queries on values
in Daisy. However, there is a method on the QueryManager
(performDistinctQuery) which executes a query and returns the list of
distinct values of the first value selected in a query. This is
currently only used for filling up query-based selection lists.

-- 
Bruno Dumon                             http://outerthought.org/
Outerthought - Open Source, Java & XML Competence Support Center
bruno at outerthought.org                          bruno at apache.org



More information about the daisy mailing list