so I have a table with topics and I am trying to select the latest topic from every category.
category_id
is the category and date
is the date created.
I cant actually find out what is the command I have to execute in order to get the latest topic of the category and then select its data.
Thanks in advance
Edit: I want to find the proper command so I can select topic with id 2 from category 1 and topic with id 3 from category 2
Hope it helps you understand what am I talking about.
id category_id content date
1 2 bla bla 12-1-2017 22:54
2 1 bla bla 12-1-2017 22:58 - latest
3 2 bla bla 12-1-2017 22:57 - latest
4 1 bla bla 12-1-2017 22:55