Added formatting to awful awful query