added sql queries