Adds SQL for Creating Database. Adds some more outputs. Fixes query for postgres