possible fix for sql