Fixed bug in group-by year query.
All facts relation now cached on disk.