Hi Roy, You have no relationship between time and date due to the de-normalising of your data.
I don't have a good answer to this and I guess this is a "classic" question. One approach is maybe to do the following: make sure you have field collapsing available. trunk or a patch maybe index not at the shop entity level but shop-opening level so your records are shop fromDate toDate closingTime 1 12/12/2010 12/12/2011 18:00 1 12/12/2011 12/12/2012 20:00 Field collapse on shop id. Note this impacts on your number of records and could be a lot of change for your app :-) I'm also not sure if field collapsing will have the desired effect on the facet counts and will behave as expected. Anyone with better knowledge? is their a better way ? Anyway, good luck with it Roy On 23 June 2011 08:29, roySolr <royrutten1...@gmail.com> wrote: > Hello, > > I have change my db dates to the correct format like 2011-01-11T00:00:00Z. > > Now i have the following data: > > > Manchester Store 2011-01-01T00:00:00Z > 2011-31-03T00:00:00Z 18:00 > Manchester Store 2011-01-04T00:00:00Z > 2011-31-12T00:00:00Z 20:00 > > The "Manchester Store" has 2 seasons with different closing times(18:00 and > 20:00). Now i have > 4 fields in SOLR. > > Companyname Manchester Store > startdate(multiV) 2011-01-01T00:00:00Z, 2011-01-04T00:00:00Z > enddate(multiV) 2011-31-03T00:00:00Z, 2011-31-12T00:00:00Z > closingTime(multiV) 18:00, 20:00 > > I want some facets like this: > > Open today(2011-23-06): > 20:00(1) > > The facet query needs to look what's the current date and needs to use that > closing time. My facet.query look like this: > > facet.query=startdate:[* TO NOW] AND enddate:[NOW TO *] AND > closingTime:"18:00" > > This returns 1 count like this: 18:00(1) > > When i use this facet.query it returns also 1 result: > > facet.query=startdate:[* TO NOW] AND enddate:[NOW TO *] AND > closingTime:"20:00" > > This result is not correct because NOW(2011-23-06) it's not open till 20:00. > It looks like there is no link between the season and the closingTime. Can > somebody helps me?? The fields in SOLR are not correct? > > Thanks Roy > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Complex-situation-tp3071936p3098875.html > Sent from the Solr - User mailing list archive at Nabble.com. >