added basic db logging for azure diagnostics. fixed cases where user could not create quiz if there were no categories available.