Quantcast
Channel: SQLServerCentral » Reporting Services » Reporting Services » Latest topics
Viewing all articles
Browse latest Browse all 2791

assign an expression to a variable !!

$
0
0
Hi,I'm working with Report Builder, I should do a sum of many values from different columns (this clumns are from a list in sharepoint )This is my expressio which does the sum : =(Lookup(Fields!Ele_Crs_Har_Q1_Ans.Value,Fields!Answer.Value,Fields!Value.Value,"Coefficient"))+(Lookup(Fields!Ele_Crs_Har_Q2_Ans.Value,Fields!Answer.Value,Fields!Value.Value,"Coefficient"))+(Lookup(Fields!Ele_Crs_Har_Q3_Ans.Value,Fields!Answer.Value,Fields!Value.Value,"Coefficient"))+(Lookup(Fields!Ele_Crs_Har_Q4_Ans.Value,Fields!Answer.Value,Fields!Value.Value,"Coefficient"))+(Lookup(Fields!Ele_Crs_Har_Q5_Ans.Value,Fields!Answer.Value,Fields!Value.Value,"Coefficient"))+(Lookup(Fields!Ele_Crs_Har_Q6_Ans.Value,Fields!Answer.Value,Fields!Value.Value,"Coefficient"))My problem is with this Expression, it wroks but i wanna assign it to a variable !!! i get an error :When the report contains multiple datasets, field references outside of a data region must be contained within aggregate functions which specify a dataset scope. I think because i use the lookup !! but i don't know how do i resolve this ? Any idea Plz ?

Viewing all articles
Browse latest Browse all 2791

Trending Articles