Fixed SQL breakage caused by fixing Mongo breakage. Fffffuuuuuu ....