Added functionallity to pull location from database