Yes, I'm all for de-normalizing when it makes sense to do so. There's no reason for this data to be normalized. I'm going to give the thread starter the benefit of the doubt and assume it's not actually about trains.
On Monday, January 14, 2013 10:10:34 AM UTC-7, Niphlod wrote: > > > > On Sunday, January 13, 2013 8:51:55 PM UTC+1, Vasile Ermicioi wrote: >> >> That way you can issue queries like db.trains.company == 'amtrack' that >>> are - usually - faster than filtering records through joins. >> >> >> you can't do db.trains.company == 'amtrack' because company is a >> reference field >> >> > I know, did you read the entire post ? > I'm not saying that he can with the original model, I'm saying that > changing the model "un-normalizing" the reference field often simplifies > both code and the underlying queries ( improving performances as a nice > side-effect ). > --

