Comment event formatting (wip)
Moved the entityGetName code
Renamed a SQL query to get the entity name