Database Knowledge Base

Howto: mysql obtain the right sorting for nested records from the same table

In those latest days I was wondering how to sort a table in mySQL that has an id a parent_id and a order column like the one that follows:

id | parent_id | ordr | title
1  | 0