Timeline of events using Dataview, Flatten & Group By - stuck

With exception of the first line with TABLE ... stuff is available sequentially down the query. The first line is then processed at the end.

In your case this has the implications that in your WHERE clause it doesn’t know you’re about to do a group by, so you shouldn’t use rows. in front of the file name.

However, when we get to process the first line after the grouping you’ll need to add just rows. in front of the values you want to list. Not rows.file. like you did for the summary, and not nothing like you did for typeIcon.

So a better version of your query would look like:

```dataview 
TABLE rows.file.link, rows.timeline-summary, rows.typeIcon
FROM #LifeTimeline 
FLATTEN {"Education": "📝","Work": "🛠️","Accomodation": "🏠", "Life Event": "❤️", "Pet": "🐱"}[rows.file.timeline-event-type] as typeIcon
WHERE file.name != "template_LifeTimeline"
GROUP BY timeline-year AS Year
```

This should work a little better. But given some empty summaries you might discover that the grouped lines are misaligned. Bummer…

And regarding the quarterly grouping, you’re able to do multiple group by, but it’ll add a another layer of rows., so you could end up with rows.rows.typeIcon or similar monstrosities. It would be better to make the first grouping do it all. In other words to group directly by the year/quarter combination.