web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

CRM online SSRS and Nested Aggregates

(0) ShareShare
ReportReport
Posted on by

I've created an ssrs report in visual studio and I have a lot of complex formulas that need to be subtotaled and totaled as part of groupings.  But because I get my data from 3 different data sets I keep getting errors.  Other than a possible hack to join the data so I have the data repeating I can't figure out how to not get the aggregate error.  In this example I'm only using 2 datasets.

The error:   The value expression from the text box '' has a nested aggregate that specifies a dataset scope.  Inner aggregates cannot specify a dataset scope.

The formula: =sum((Floor(Sum(Fields!new_secfeerateValue.Value, "AdminTable")) * -100 * ((Fields!new_quantityValue.Value * Fields!stockprice_new_priceValue.Value) + Fields!new_commissionsfeesValue.Value)) / 100))

I tried using code and that worked, but I received an error in CRM while uploading the report:

This Report can't upload because there are restrictions with SQL Servier Reporitng Services reports Definition Languare (RDL) sandboxing is enabled.

I appreciate any help figuring this out.

*This post is locked for comments

I have the same question (0)
  • Emad Hanna Profile Picture
    on at

    I found a solution that works for me but it's a bit of a workaround.  I related the tables N:1 in CRM and created a real time workflow that auto links the two tables so when the user creates or uploads data in the primary table the secondary table information is autol-related and it also solves the primary issue with ssrs which is I can have only 1 data set to sum(that's the real issue).  Apparently SSRS doesn't like to double aggregates if you have more than 1 data set.  So by combining both tables I got around that and I can now sum the sum fields.

    Hope that helps the next person.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
JS-09031509-0 Profile Picture

JS-09031509-0 3

#2
AS-17030037-0 Profile Picture

AS-17030037-0 2

#2
Mark Eckert Profile Picture

Mark Eckert 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans