fixed typo and added selectSync syncronouse function for select queries