We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now

x

Error in SSRS "Aggregate expression without scope

Medium Priority
2,923 Views
Last Modified: 2012-08-13
I am trying to concatenate 3 columns in a textbox in SSRS and get the following error:
The Value expression for the textbox Name uses an aggregate expression without a scope.  A scope is required for all aggregates used outside of a data region unless the report contains exactly one data set.  Below is the expression I am using for the textbox.      
What am I doing wrong?
=First(Fields!First_Name.Value, "Driver") &" "& First(Fields!Middle_Name.Value, "Driver")&" "& First(Fields!Last_Name.Value, "Driver")

Open in new window

Comment
Watch Question

CERTIFIED EXPERT

Commented:
I tried your syntax but modified to my report and could use the textbox anywhere, header or in table rows.

Is "Driver" your dataset?
Does this article help also?
http://social.technet.microsoft.com/Forums/en-US/sqlreportingservices/thread/b2fdefc9-ae76-43cc-a944-e587658c480b/

Author

Commented:
Yes.  It is a  website data source.  The article said to specify the dataset which I have so I cannot figure out what the problem.  
CERTIFIED EXPERT
Commented:
How about talkiing the 3rd part out. So just concentrate on the first 2 peices of data?
Are your & signs correct (ie the third & sign has no space before it....
=First(Fields!First_Name.Value, "Driver") &" "& First(Fields!Middle_Name.Value, "Driver")&" "& First(Fields!Last_Name.Value, "Driver")

Clutching at straws here.

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts

Author

Commented:
Put space between variable and & and it worked.

Author

Commented:
Resolved
Commented:
REsolved
CERTIFIED EXPERT

Commented:
Great
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.