added remaining sql queries