Expression in RDLC textbox - mysql

Is it possible to write a query as an expression in a textbox in rdlc? I am trying to show row position of a field after ordering them in descending order.
If not possible, how can I achieve this apart from passing the values via parameters?

Related

Sorting in Tablix Computed Column

Friends,
I am using Tablix Control in RDLC to generate matrix report. In the last column of my matrix (group) report I have defined a formula using expression Now my user want to sort this column by ascending or descending.
(Criteria will be sent to report via Report Parameter).
I found sorting under Row Group - > Group Properties -> Sorting.....
But I am not sure how to do sorting on column which is calculated based on formula.
How can I do that? Can any one tell?
New answer:
If you do not need to use a parameter for triggering this sorting, then Interactive Sorting would accomplish exactly what you are looking for. Right click on the header of the column in question and you should see Interactive Sorting.
If it needs to be a parameter for whatever reason, then it would depend on the data type. If it is some kind of numeric type, then you could have the parameter value be either 1 (ascending) or -1 (descending). You would then sort on the parameter multiplied by the expression for that column.

SSRS has a hidded group statement that is not in the dataset query. How to find it?

REPORT BUILDER 3.0
I am changing the data sets of our reports to standard data sets. In some cases the names of fields have changed. Despite changing the cells to the new names I get an error of:
"The Group expression for the grouping ‘companyname’ refers to the field ‘companyname’. Report item expressions can only refer to fields within the current dataset scope or, if inside an aggregate, the specified dataset scope. Letters in the names of fields must use the correct case.
"companyname" changed to CompanyName and there is no group by companyname in the Dataset SQL. How can I change that in SSRS?
Whenever I've faced this, the places to check are:
Row Groups
Column Groups
Header text boxes for interactive sorting
9 times out of 10 when I can't find it, it's in the interactive sorting on text boxes.

How to get the textbox name of current sorting SSRS report

I enabled interactive sorting on some textbox inside a table, I need put the textbox name to one expression, so visitor know which sorting is using for this table.
How can I get it? Is there a formula or report parameter to use?

Order SSRS report column

I have a table in SSRS with a column which uses the expression
(Reportitems!Textbox71.Value / Reportitems!morCodeTextbox.Value)
This obviously divides one table filed by another and displays a percentage for each line.
I'm struggling to see how I can then order this percentage column to show the highest percentage in first row and then descending results. When I try and sort the table by going to table properties the available fields only include those from SQL query. Am getting errors when trying to use an expression to sort. Tells me that I can't use report items in sort expressions.
Does anybody know how I can achieve this?
you need to add a Sorting to table by expression: "(Reportitems!Textbox71.Value / Reportitems!morCodeTextbox.Value)"

Reporting services, sum all rows of a column

I'm using reporting services 2005, I have a report with a table(table1) which displays data from an sql database.
A column on the table displays numbers. I want the total of all rows for that column, on a textbox(textbox3)
of another table(lets call it table2).
I tried placing this on a table2 textbox: =Sum(ReportItems!textbox1.Value)
texbox1 is the one from the table1. But when going to the Preview tab i get:
Error 2 [rsAggregateReportItemInBody] The Value expression for the textbox 'textbox3' uses an aggregate function on a report item. Aggregate functions can be used only on report items contained in page headers and footers.
How can I solve this?
Thanks.
You've got a couple of options.
The first is to use an expression similar to the following in the Textbox:
=Sum(Fields!value.Value, "Values")
Where Values is the name of the DataSet you want to aggregate.
Here you're creating an aggregate expression and specifying the scope where it executes, in this case a DataSet, i.e. aggregate all values in the DataSet.
As you can see from the error you're getting you can reference a report item with an aggregate, but if you're displaying the aggregate in the table header or footer you can reference that Textbox.
Here's a simple report showing both methods:
Hopefully you can adapt one method to your report.