[TYPO3-Solr] sortBy not working?

Ingo Renner ingo at typo3.org
Thu Mar 29 15:13:32 CEST 2012


Am 23.03.12 14:40, schrieb Jigal van Hemert:

Hi Jigal,

> I added a dynamic field to each index.queue:
> sorting_intS = TEXT
> sorting_intS = 4
> (value different for each queue)

this is ok

> If I add a sorting:
> sorting.fields {
> sorting_intS = 1
> sorting_intS.label = sorting_type2

here's the wrong part, this should be like this (in 2.0/2.5):

sorting = 1
sorting {
	options {
		mySortingOptionName {
			field = sorting_intS
			label = Sort me NOW!
		}
	}
}

> If I try to use it as default sortBy then the relevancy is still used:
> plugin.tx_solr.search.query.sortBy = sorting_intS asc

works for me, can you enable this please and have a look what is sent to 
the Solr server:
plugin.tx_solr.logging.query.rawGet = 1
plugin.tx_solr.logging.query.queryString = 1



> A second question: does the file index or index.queue support additional
> fields? I couldn't find it in the sources when I took a quick look.

There is plugin.tx_solr.index.additionalFields{} but this is deprecated 
since 2.0 now. Rather explicitly define what fields you need for each 
type in plugin.tx_solr.index.queue.*.fields{}

For files there's at least a way to do that with PHP already, but not 
through TS yet.


best
Ingo

-- 
Ingo Renner
TYPO3 Core Developer, Release Manager TYPO3 4.2, Admin Google Summer of Code

TYPO3 - Open Source Enterprise Content Management System
http://typo3.org

Apache Solr for TYPO3 -
Open Source Enterprise Search meets Open Source Enterprise CMS
http://www.typo3-solr.com


More information about the TYPO3-project-solr mailing list