compilation fix for sql errors reporting to log