Describe the bug
Object reference not set to an instance of an object
To Reproduce
Query to reproduce the behavior:
WITH ComponentInSeveralSolutions AS (
SELECT SC.objectid,componenttypename,componenttype, STRING_AGG(S.uniquename, ';') AS SolutionName
FROM solutioncomponent SC
LEFT OUTER JOIN solution S ON SC.solutionid = S.solutionid
WHERE 1=0
GROUP BY SC.objectid,componenttypename,componenttype
HAVING COUNT(*)>1)
SELECT *,
CASE
WHEN ComponentType = 9 THEN (SELECT W.displayname FROM metadata.globaloptionset W WHERE W.metadataid = objectid)
ELSE NULL
END AS ComponentName
FROM ComponentInSeveralSolutions
order by Componenttype, ComponentName
Expected behavior
The correct result
Screenshots
Environment (please complete the following information):
- SQL 4 CDS edition: XrmToolBox
- Results of
SELECT @@VERSION: Microsoft Dataverse - 9.2.25082.179
SQL 4 CDS - 10.1.0.0
sept. 02 2025 11:14:15
Copyright © 2020 - 2025 Mark Carrington
Additional context
Notice that with version 9.6.1 of the engine, I do not have the issue.
Sponsorship
If you find this tool useful, please consider sponsoring its development.
Describe the bug
Object reference not set to an instance of an object
To Reproduce
Query to reproduce the behavior:
Expected behavior
The correct result
Screenshots
Environment (please complete the following information):
SELECT @@VERSION: Microsoft Dataverse - 9.2.25082.179SQL 4 CDS - 10.1.0.0
sept. 02 2025 11:14:15
Copyright © 2020 - 2025 Mark Carrington
Additional context
Notice that with version 9.6.1 of the engine, I do not have the issue.
Sponsorship
If you find this tool useful, please consider sponsoring its development.