Share via

Config_Mgr_CML_2509_ Installation error

永明 陈 0 Reputation points
2026-01-21T07:51:56.0166667+00:00

Moderator note: Moved from SQL Server Database Engine.


An error occurred during the installation process. The installer was unable to create the necessary database tables. The database is a patch for SQL2022 CU22 (SQLServer2022-KB5074819-x64). The specific log is as follows:

*** MERGE [dbo].[LU_LicensedProduct] AS TARGET ~ using (select [LicensedProductID], [ProductPool], [ProductName], ~ [FamilyName], [VersionSequence], [VersionCode], ~ GETUTCDATE() , N'$CD' ~ from tempdb.dbo.temp_LU_LicensedProduct) ~ as SOURCE ( [LicensedProductID], [ProductPool], [ProductName], ~ [FamilyName], [VersionSequence], [VersionCode], ~ [LastUpdated], [SourceSite]) ~ ON SOURCE.[LicensedProductID] = TARGET.[LicensedProductID] ~ when matched and (~ TARGET.[ProductPool] != SOURCE.[ProductPool] OR ~ TARGET.[ProductName] != SOURCE.[ProductName] OR ~ TARGET.[FamilyName] != SOURCE.[FamilyName] OR ~ TARGET.[VersionSequence] != SOURCE.[VersionSequence] OR ~ TARGET.[VersionCode] != SOURCE.[VersionCode] OR ~ TARGET.[SourceSite] != SOURCE.[SourceSite]) ~ then ~ UPDATE SET ~ [ProductPool] = SOURCE.[ProductPool], ~ [ProductName] = SOURCE. $$<Configuration Manager Setup><01-21-2026 15:47:39.317-480><thread=4140 (0x102C)>

*** [23000][515][Microsoft][ODBC Driver 18 for SQL Server][SQL Server]不能将值 NULL 插入列 'VersionCode',表 'CM_P01.dbo.LU_LicensedProduct';列不允许有 Null 值。UPDATE 失败。 $$<Configuration Manager Setup><01-21-2026 15:47:39.346-480><thread=4140 (0x102C)>

INFO: Executing SQL Server command: < MERGE [dbo].[LU_LicensedProduct] AS TARGET ~ using (select [LicensedProductID], [ProductPool], [ProductName], ~ [FamilyName], [VersionSequence], [VersionCode], ~ GETUTCDATE() , N'$CD' ~ from tempdb.dbo.temp_LU_LicensedProduct) ~ as SOURCE ( [LicensedProductID], [ProductPool], [ProductName], ~ [FamilyName], [VersionSequence], [VersionCode], ~ [LastUpdated], [SourceSite]) ~ ON SOURCE.[LicensedProductID] = TARGET.[LicensedProductID] ~ when matched and (~ TARGET.[ProductPool] != SOURCE.[ProductPool] OR ~ TARGET.[ProductName] != SOURCE.[ProductName] OR ~ TARGET.[FamilyName] != SOURCE.[FamilyName] OR ~ TARGET.[VersionSequence] != SOURCE.[VersionSequence] OR ~ TARGET.[VersionCode] != SOURCE.[VersionCode] OR ~ TARGET.[SourceSite] != SOURCE.[SourceSite]) ~ then ~ UPDATE SET ~ [ProductPool] = SOURCE.[ProductPool], ~ [ProductName] = SOURCE.[ProductName], ~ [FamilyName] = SOURCE.[FamilyName], ~ [VersionSequence] = SOURCE.[VersionSequence], ~ [VersionCode] = SOURCE.[VersionCode], ~ [LastUpdated] = SOURCE.[LastUpdated], ~ [SourceSite] = SOURCE.[SourceSite] ~ when not matched by TARGET then ~ INSERT([LicensedProductID], [ProductPool], [ProductName], [FamilyName], [VersionSequence], [VersionCode], ~ [LastUpdated], [SourceSite]) ~ VALUES(SOURCE.[LicensedProductID], SOURCE.[ProductPool], SOURCE.[ProductName], ~ SOURCE.[FamilyName], SOURCE.[VersionSequence], SOURCE.[VersionCode], ~ SOURCE.[LastUpdated], SOURCE.[SourceSite]); ~ TRUNCATE TABLE tempdb.dbo.temp_LU_LicensedProduct ~> $$<Configuration Manager Setup><01-21-2026 15:47:39.363-480><thread=4140 (0x102C)>

ERROR: Failed to execute SQL Server script: MERGE [dbo].[LU_LicensedProduct] AS TARGET ~ using (select [LicensedProductID], [ProductPool], [ProductName], ~ [FamilyName], [VersionSequence], [VersionCode], ~ GETUTCDATE() , N'$CD' ~ from tempdb.dbo.temp_LU_LicensedProduct) ~ as SOURCE ( [LicensedProductID], [ProductPool], [ProductName], ~ [FamilyName], [VersionSequence], [VersionCode], ~ [LastUpdated], [SourceSite]) ~ ON SOURCE.[LicensedProductID] = TARGET.[LicensedProductID] ~ when matched and (~ TARGET.[ProductPool] != SOURCE.[ProductPool] OR ~ TARGET.[ProductName] != SOURCE.[ProductName] OR ~ TARGET.[FamilyName] != SOURCE.[FamilyName] OR ~ TARGET.[VersionSequence] != SOURCE.[VersionSequence] OR ~ TARGET.[VersionCode] != SOURCE.[VersionCode] OR ~ TARGET.[SourceSite] != SOURCE.[SourceSite]) ~ then ~ UPDATE SET ~ [ProductPool] = SOURCE.[ProductPool], ~ [ProductName] = SOURCE.[ProductName], ~ [FamilyName] = SOURCE.[FamilyName], ~ [VersionSequence] = SOURCE.[VersionSequence], ~ [VersionCode] = SOURCE.[VersionCode], ~ [LastUpdated] = SOURCE.[LastUpdated], ~ [SourceSite] = SOURCE.[SourceSite] ~ when not matched by TARGET then ~ INSERT([LicensedProductID], [ProductPool], [ProductName], [FamilyName], [VersionSequence], [VersionCode], ~ [LastUpdated], [SourceSite]) ~ VALUES(SOURCE.[LicensedProductID], SOURCE.[ProductPool], SOURCE.[ProductName], ~ SOURCE.[FamilyName], SOURCE.[VersionSequence], SOURCE.[VersionCode], ~ SOURCE.[LastUpdated], SOURCE.[SourceSite]); ~ TRUNCATE TABLE tempdb.dbo.temp_LU_LicensedProduct ~ $$<Configuration Manager Setup><01-21-2026 15:47:39.377-480><thread=4140 (0x102C)>

ERROR: SQL Server error: <> $$<Configuration Manager Setup><01-21-2026 15:47:39.401-480><thread=4140 (0x102C)>

*** IF OBJECT_ID('tempdb.dbo.temp_LU_LicensedProduct') IS NOT NULL ~ DROP TABLE tempdb.dbo.temp_LU_LicensedProduct ~ $$<Configuration Manager Setup><01-21-2026 15:47:39.418-480><thread=4140 (0x102C)>

*** [24000][0][Microsoft][ODBC Driver 18 for SQL Server]无效的游标状态 $$<Configuration Manager Setup><01-21-2026 15:47:39.434-480><thread=4140 (0x102C)>

INFO: Executing SQL Server command: < IF OBJECT_ID('tempdb.dbo.temp_LU_LicensedProduct') IS NOT NULL ~ DROP TABLE tempdb.dbo.temp_LU_LicensedProduct ~> $$<Configuration Manager Setup><01-21-2026 15:47:39.448-480><thread=4140 (0x102C)>

ERROR: FAILED to import data to table LU_LicensedProduct $$<Configuration Manager Setup><01-21-2026 15:47:39.462-480><thread=4140 (0x102C)>

ERROR: Failed to import data from CSV files $$<Configuration Manager Setup><01-21-2026 15:47:39.474-480><thread=4140 (0x102C)>

ERROR: Failed to import Asset Intelligence data into the site database.~ $$<Configuration Manager Setup><01-21-2026 15:47:39.583-480><thread=4140 (0x102C)>

Not recovery mode or not top level site. Skip restoring client piloting packages. $$<Configuration Manager Setup><01-21-2026 15:47:39.616-480><thread=4140 (0x102C)>

~~===================== Completed Configuration Manager Server Setup ===================== $$<Configuration Manager Setup><01-21-2026 15:47:39.645-480><thread=4140 (0x102C)>

Microsoft Security | Intune | Configuration Manager | Deployment
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Lakshmi Narayana Garikapati 925 Reputation points Microsoft External Staff Moderator
    2026-01-22T05:08:18.15+00:00

    Hi Yongming Chen,

    Thanks for the reaching out to SQL Q & A Forum

    Thanks for sharing the full snippet from ConfigMgrSetup.log that helps a lot. You’re installing Configuration Manager (current branch) with SQL Server 2022 CU22 underneath, and the setup stops during the Asset Intelligence (AI) catalog import when it runs a MERGE into dbo.LU_LicensedProduct:

    Cannot insert the value NULL into column Version Code' ...UPDATE fails.\ followed by Invalid cursor state and then Failed to import data from CSV files.

    1. Check your ODBC 18 build
      • Apps & Features → Microsoft ODBC Driver 18 for SQL Server → Version (or check the registry HKLM\SOFTWARE\Microsoft\MSODBCSQL18\InstalledVersion).
      • If it shows 18.6.1.x, that aligns with the failure you’re seeing.
      https://learn.microsoft.com/en-us/sql/connect/odbc/download-odbc-driver-for-sql-server?view=sql-server-ver17
    2. Uninstall ODBC 18.6.1.x
      • Remove Microsoft ODBC Driver 18 for SQL Server from Programs & Features.
    3. Install ODBC 18.5.x (known-good for this setup step)
      • Administrators have reported success with 18.5.1 and 18.5.2.1. If you don’t already host a vetted copy in your software repo, you can reference Microsoft’s official download page for ODBC 18 and the release announcement for 18.5 (use your normal software intake/packaging process to get the specific 18.5.x MSI):
      • Download ODBC Driver for SQL Server (official Learn page) – contains links to the Windows redistributables (note: the landing page always highlights the latest GA; obtain the 18.5.x installer that your org approves). https://techcommunity.microsoft.com/blog/sqlserver/odbc-driver-18-5-for-sql-server-released/4395539
      • ODBC 18.5 release note (TechCommunity) – confirms the 18.5 line and links to Microsoft downloads.
    4. Re-run ConfigMgr setup
      • From CD.Latest\SMSSETUP\BIN\X64\Setup.exe on the site server and choose Recover (or re-run the install if it rolled back). The AI import should now succeed, and the site setup will complete.

    Field notes from other admins and a Microsoft Q&A thread confirm that simply downgrading from 18.6.1 18.5.x is sufficient; no DB surgery is needed. https://learn.microsoft.com/en-us/answers/questions/5704369/sccm-2403-2509-installation-fails-with-odbc-driver

    Hope this Helps!

    Thanks

    Lakshmi


  2. Q&A Assist
    2026-01-21T07:54:01.58+00:00
    AI generated content. This question contains an answer created with AI from Q&A Assist. Learn more

    The installation error you are experiencing appears to be related to the inability to insert a NULL value into the VersionCode column of the LU_LicensedProduct table. This typically indicates that the data being imported does not meet the constraints defined in the database schema.

    Here are some steps to help troubleshoot and potentially resolve this issue:

    1. Validate Source Data: Ensure that the data being imported into the temp_LU_LicensedProduct table does not contain NULL values for the VersionCode column. It may be necessary to check the source data for completeness and correctness before the import.
    2. Check Database Schema: Verify that the LU_LicensedProduct table schema is correctly defined, particularly that the VersionCode column is set to NOT NULL. If this column is required, ensure that it has a default value if applicable.
    3. SQL Server Updates: Since you are using SQL Server 2022 CU22, ensure that all relevant updates and patches are applied to your SQL Server instance. Compatibility issues can sometimes arise with specific versions of SQL Server.
    4. Review Installation Logs: Examine the detailed logs for any additional error messages that may provide more context regarding the failure. Look for any preceding errors that could indicate issues during the data preparation phase.
    5. Execute SQL Commands Manually: Try executing the SQL commands that are failing manually to see if you can replicate the error outside of the installation process. This can help determine if the problem lies with the data or the installation script.
    6. Consult Official Documentation: Refer to the official documentation for any known issues or additional troubleshooting steps related to SQL Server and Configuration Manager installations.

    If these steps do not resolve the issue, consider reaching out to Microsoft Support for further assistance.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.