"Can you give examples of this kind of job, other than those created directly by the government?"
Plenty of "useless jobs" exist. It comes back to the classic agency problem. What is best for the market/company/shareholders is often not what is best for the employees working at the companies.