Thread Details

 Count function


Post by Bradley Tompkins
Joined 1/25/2021
Posted 2/22/2021 10:21 PM

This query works in the console, but not in SOQL Studio: 

SELECT COUNT_DISTINCT(City__c) FROM property__c

The example is from the Dreamhouse test data.
Thank you,

Bradley

Post by Bradley Tompkins
Joined 1/25/2021
Posted 2/22/2021 10:30 PM

I notice that Max also needs attention:  this query fails with "Object reference not set to an instance of an object"

SELECT MAX(Status__c), Broker__r.Name
FROM Property__c
GROUP BY Broker__r.Name
HAVING MAX(status__c) = 'Closed'
Post by Administrator
Visual Software Systems
Joined 1/01/2016
Posted 2/23/2021 12:00 PM

Hi Bradley,

These issues have the same root cause as the count(field) issue you reported earlier.  All aggregate functions were affected except count(), as you reported, and all are fixed in the next release of SOQL Studio, due out in March.

Post by Administrator
Visual Software Systems
Joined 1/01/2016
Solved
Posted 3/15/2021 6:23 PM

This issue has been resolved in SOQL Studio 2021.1.290, released Monday, 3/15/2021

Log in to reply to this post.