Error while importing drivers in SCCM
*** [25000][266][Microsoft][SQL Server Native Client 11.0][SQL Server]Transaction count after EXECUTE indicates a mismatching number of BEGIN and COMMIT statements. Previous count = 1, current count = 0. : sp_SetupCI SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
*~*~[25000][266][Microsoft][SQL Server Native Client 11.0][SQL Server]Transaction count after EXECUTE indicates a mismatching number of BEGIN and COMMIT statements. Previous count = 1, current count = 0. : sp_SetupCI ThreadID : 8788 , DbError: 266 , Sev: 16~*~* SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
*** declare @rc int, @errxml xml, @errmsg nvarchar(max); EXEC @rc=sp_SetupCI 16784636, 0, @errxml out, @errmsg out; select @rc, @errxml, @errmsg SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
*** [42000][50000][Microsoft][SQL Server Native Client 11.0][SQL Server]ERROR 245, Level 16, State 1, Procedure sp_SetupCIContent, Line 50, Message: Conversion failed when converting the nvarchar value ‘19.51.42.2’ to data type int. : spRethrowError SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
*~*~[42000][50000][Microsoft][SQL Server Native Client 11.0][SQL Server]ERROR 245, Level 16, State 1, Procedure sp_SetupCIContent, Line 50, Message: Conversion failed when converting the nvarchar value ‘19.51.42.2’ to data type int. : spRethrowError [25000][266][Microsoft][SQL Server Native Client 11.0][SQL Server]Transaction count after EXECUTE indicates a mismatching number of BEGIN and COMMIT statements. Previous count = 1, current count = 0. : sp_SetupCI ThreadID : 8788 , DbError: 50000 , Sev: 16~*~* SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
ERROR CCISource::InsertObject returned -1 SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
*~*~X:\bt\1116398\repo\src\SiteServer\SDK_Provider\SMSProv\sspconfigurationitem.cpp(1940) : CSspConfigurationItem: SQL_ERROR~ SQL Error: [42000][50000][Microsoft][SQL Server Native Client 11.0][SQL Server]ERROR 245, Level 16, State 1, Procedure sp_SetupCIContent, Line 50, Message: Conversion failed when converting the nvarchar value ‘19.51.42.2’ to data type int. : spRethrowError~*~* SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
*~*~CSspConfigurationItem: SQL_ERROR [42000][50000][Microsoft][SQL Server Native Client 11.0][SQL Server]ERROR 245, Level 16, State 1, Procedure sp_SetupCIContent, Line 50, Message: Conversion failed when converting the nvarchar value ‘19.51.42.2’ to data type int. : spRethrowError~*~* SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
Auditing: User DEMO\cmadmin called an audited method of an instance of class SMS_Driver. SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
CExtUserContext::LeaveThread : Releasing IWbemContextPtr=-2076680688 SMS Provider 1/7/2023 7:00:19 PM 8788 (0x2254)
SOLUTION
- Set SQL Compatibility Level to 150
- Open SQL MGMT Studio and execute below query on SMS DB
SET XACT_ABORT ON
SET NoCount ON
select compatibility_level from sys.databases where name =‘CM_PRI’
ALTER DATABASE CM_PRI
SET COMPATIBILITY_LEVEL = 150;
GO