Updated SQL methods