updated testing and added more SQL