function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Shashi PatowaryShashi Patowary 

SOQL Relationship query - Unknown Execption

Hi,
 
We are getting a VF page exception while generating a PDF. We pinned down to a relationship query which is trying to pull accounts and its child records. Please find the simplified query below. The query works fine if we include only one record but throws below error if we include multiple account ids in “IN” filter. Interestingly same query works fine in Production Dev console. Our prod is running on Winter,16 while sandbox is updated to Spring,16. Please let us know if this is a known issue in Spring,16.
Please note this that below sub query is causing the issue. If we remove this sub query , the query works.
(SELECT name FROM Family__r)
Query:
SELECT Name,
 (SELECT Id, Name FROM Opportunities WHERE (Status__c = 'Disbursed' OR Status__c = 'Closed')
 ORDER BY Actual_DisbursementDate__c DESC NULLS FIRST LIMIT 1),
 (SELECT name FROM Family__r),
 (SELECT id
 FROM Secondary_Customer_Details__r LIMIT 1) FROM Account
 WHERE id in ('00156000002qhwrAAA', '001560000037uexAAA')
Exception Message:
Unknown Exception
[object Object]: An unexpected error occurred. Please include this ErrorId if you contact support: 2139555223-9360 (741305289)
 
Thanks,
Shashi
 
Shashi PatowaryShashi Patowary
Hi,

Anyone facing this issue - 'SOQL Relationship query - Unknown Execption' in Spring,16 org. Kindly let me know.

Thanks,
Shashi