Hi Sergiu, all
I see in the XWikiHibernateStore that #countDocuments do distinct
documents by language while #searchDocuments does not.
I would have expect both to have the same behavior, so that we can use
them safely using the same query as input (for example for pagination).
Is there a reason for originally doing "select count(*)" versus select
"count(distinct doc.fullName)" ?
I think in any case we should have this API that does not distinct by
language. Should it replace the current behavior ? or should we add a
new API #countDocuments(String wheresql, boolean distinctFullname,
XWikiContext context) ?
Thanks,
Jerome.