From kde-commits Thu Jan 20 17:14:13 2011 From: Sebastian Trueg Date: Thu, 20 Jan 2011 17:14:13 +0000 To: kde-commits Subject: KDE/kdebase/runtime/nepomuk/services/queryservice Message-Id: <20110120171413.F16A2AC8B7 () svn ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-commits&m=129554368820124 SVN commit 1215989 by trueg: There is no point in counting results when a limit is set. Virtuoso will ignore it anyway and the query might take very long. M +3 -1 folder.cpp --- trunk/KDE/kdebase/runtime/nepomuk/services/queryservice/folder.cpp #1215988:1215989 @@ -93,8 +93,10 @@ QueryService::searchThreadPool()->start( m_currentSearchRunnable, 1 ); // we only need the count for initialListingDone + // count with a limit is pointless since Virtuoso will ignore the limit if ( !m_initialListingDone && - !m_isSparqlQueryFolder ) { + !m_isSparqlQueryFolder && + m_query.limit() == 0 ) { m_currentCountQueryRunnable = new CountQueryRunnable( this ); QueryService::searchThreadPool()->start( m_currentCountQueryRunnable, 0 ); }