Report rows differ from SQL result - reporting-services

I am stumped.
I have a select statement that returns the data fine in the data pane, but in the resulting report, one row is our of sort order and falls about 25 rows down in the data where it shouldn't be.
How do I trouble shoot something like that?
Thanks!i

Somewhere in the report you must be sorting the dataset. In this case, the data will look fine in the data pane but will be out of the expected order in the report. Try adding a brand new table to the report and apply the dataset. It should match the data pane.

How do I trouble shoot something like that?
You start by posting the select statement here so we can help without having to hone our psychic debugging skills :-)
It's possible that you're not ordering on every column you think you are. It's also possible that SSRS re-orders the data even after you've retrieved it.
They'd be the first two places I'd look.

Related

Table within a Table | Power BI Report Builder

When writing expressions for a row in Power BI Report Builder, things line up just fine until you get data that is a lot of text.
This is a prime example
I have 'cangrow' to true on all of my individual cells as well as the row group / row itself. Nothing seems to fix this. Is there any way to do this so the rows expand accordingly?
Ideally, I'd something like this.
EDIT:
I believe the real problem is that I wasn't using a subtables because subtables look really bad when there are column groupings that block the merging of cells.
I'm now trying to find a way to basically add a completely separate table beneath the top table but still connected to be reported each match. First step would be find a way to have a separate data source in the subtable. Step two would be to allow the formatting of the subtable without the structure of the first.
I can't extend the subtable to the final column because of a required column group. And my expressions can't really do what I need them to without changing the dataset to something other than the main table.
Thanks for the help!
FINAL EDIT 2:
1) To resolve the separate dataset problem, I had to write a disgusting query to join the two sets I was using into one. I'm not sure there is a way to do that with Power BI Report Builder, although there should be.
2) I had to put the two separate tables into a list so they would be okay with formatting.
Got my problem solved, but in a round about way.
1) To resolve the separate dataset problem, I had to write a disgusting query to join the two sets I was using into one. I'm not sure there is a way to do that with Power BI Report Builder, although there should be.
2) I had to put the two separate tables into a list so they would be okay with formatting.
Got my problem solved, but in a round about way.

Report builder 3.0 Using Reportitems!TexboxXX.Value sometimes creates multiple boxes. Why?

I have 6 Datasets each one is the same query but has a different WHERE clause based on employee type. They generate 6 tables. At the top of the report there is a summary table which uses reportitems!textboxXX.value to grab the totals for 2 particular fields from all the tables. I'm also using a StartDate and EndDate parameter. Each reportitems! expression in the table comes from a different dataset in the report if that is relevant.
When I run the report using dates from yesterday back to the 9th of May I get the desired output.
But when I go to the 8th I get multiple rows all the same.
and as I go even further back I get even more rows of the same information. To my knowledge nothing interesting or different happened on the 8th of May and the tables further down the report look exactly the same. Any idea what might be causing this? The design view looks like this if that helps. There's no grouping or filters on the table.
Still not certain about the mechanics behind this but I found a 'solution' so I figured I'd post it. I just made a new dataset for my summary tables where the query was simply SELECT 1. Now I get a single row every time.

SSRS change default DataSet

I have an SSRS report with a dataset from a certain database. I've gone to the trouble of creating a query that (hopefully) imports the data from a more accurate source. What I want to do is potentially delete the first source, and then use the second source. However the only thing I've found online tells me I must:
=First(Field!MyField.Value,"Better Source")
I really just want to try to switch everything out.
If you added a new/replaced the current DataSet with the new query, you can change the column names to match the ones in the current Tablix/Matrix (the same Aliases/names within the Query Designer).
That way, your fields will be within the DataSet and you will see Fields!Myfield.Value instead of First(Fields!Myfield.Value)
Let me know if that helps

SSRS ignore a field result

I guys
I'm having a slight problem with a report im currently writing.
So when i run this report it gives me a list of outcomes from a data source.
One of results is 'Closed' I want to exclude this outcome in my report. I cant exclude this in my SQL code as it doesn't bring back the null values. ( when no outcome has been given to a task yet i.e no one has had the time to do it yet i have set that in the expression to 'No Outcome'.)
So i want to know if anyone can edit my expression so it does not bring back the value of 'Closed'
=IIF(IsNothing(Fields!OutcomeDescription.Value),"No outcome",Fields!OutcomeDescription.Value)
Any Help on this would be great sorry if iv not explained this well.
Rusty
To do this, you'll want to add a filter to either your dataset or your table object - whichever is most appropriate for your needs.
For a dataset filter, merely open your dataset properties, and look for the filters tab. For a table, you'll need to go into the tablix properties. Setting up a filter from there is simple.
Filtering at the dataset level will drop all of the filtered records before any controls on the report could access them. Filtering at the object level would drop the filtered records from the control, but they would still be available to other controls. If your report only consists of a single table, and no additional objects, I'd recommend filtering on the dataset.

MS Access - using multiple queries in 1 report

I have about 35 queries in a large MS Access (2007) database that I would like to use in a report. However, I don't want to create reports for each query, but would rather include multiple queries in one report. The other questions relating to this on SO seem to be related to tables, but I am mainly concerned with just queries.
I have looked at several solutions so far, none of which seem to help:
1) DLookup - returns one value. I need to populate a report with many values from each query.
2) Subreports - I have tried to create text boxes to link my query data, but since they are unbound, it won't let me.
3) Yelling at it. I keep yelling at Access and it doesn't seem to help.
4) One giant query to get the values from all the smaller queries - it doesn't recognize the expressions I built in the smaller queries. Example: CustomerCount = DCount("[Customer_ID]","[Customers]"). Error: 'CustomerCount' is unrecognized.
Any ideas would be greatly appreciated.
Thanks,
If you are creating a report from one query that is made up of multiple subqueries, you can do this by populating textboxes. If looking at the properties on the report > Data tab > Control Source, you would place the name of the your subquery from your giant query and then the value you that you want.
For example:
Master query
SELECT
[Deb<30].CountOfACCT_ID, [Deb<30].SumOfB001,
[Deb<60].CountOfACCT_ID, [Deb<60].SumOfB001,
[Deb<90].CountOfACCT_ID, [Deb<90].SumOfB001,
[Deb>90].CountOfACCT_ID, [Deb>90].SumOfB001,
TodaysHD.CountOfACCT_ID, TodaysHD.SumOfB001,
TodaysLD.CountOfACCT_ID, TodaysLD.SumOfB001,
Part.CountOfACCT_ID, Part.SumOfB001,
FROM [Deb<30], [Deb<60], [Deb<90], [Deb>90], TodaysHD, TodaysLD, Part;
Each of the items in the FROM portion are subqueries being pulled into the master query. Then in your report you would populate the Control Source with [Deb<30].CountOfACCT_ID or whatever value you need from the master query. I have this setup in multiple reports in my application so it should work.
as for 2) you should be able to bind your controls, your subreport should have a record-source.
Else, try listboxes, their graphical apperance isn't exactly flexible, but they might get the job done.
regards,
//t