-
-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to cast object of type 'System.Guid' to type 'System.Data.SqlTypes.INullable' #498
Comments
I'm struggling to reproduce this error. Can you simplify your query to use only standard entity types and still get the same error? So far I can't get it to generate the |
The result of
The simplify query is SELECT DISTINCT
c.contactid,
CASE
WHEN c.lastname = pc.lastname THEN 1
WHEN c.mobilephone = pc.mobilephone THEN 2
ELSE 0
END AS flag
FROM lead AS l
INNER JOIN contact AS c ON l.customerid = c.contactid
LEFT JOIN account AS ca ON c.contactid = ca.primarycontactid
INNER JOIN contact AS pc ON l.parentcontactid = pc.contactid
LEFT JOIN account AS pca ON c.contactid = pca.primarycontactid
WHERE c.contactid IN (SELECT contactid FROM contact WHERE modifiedon = today()) |
Thanks, that’s given me what I need to reproduce it, I should be able to get this fixed for the next release. In the meantime you should be able to avoid the error by rewriting your WHERE clause without the IN: WHERE ccr.new_role = 100000000
AND c.modifiedon = yesterday()
AND c.statuscode = 100000000 |
Hi,
I use the version 9.1.0 and when I try to run this query
I have the following error:
I found a problem in line 747-748 of the Sql4Cds/MarkMpn.Sql4Cds.Engine/ExecutionPlan/FetchXmlScan.cs file with key
Expr1.new_contractid
The text was updated successfully, but these errors were encountered: