LPS-33464 LPS-33337 Bad refactor will cause the use of an incorrect connection when using databases which are not SQLServer