SSRS Dynamically Show Data - ssrs-2012

I am wondering if you can have other tables show based on the value selected in the main table. I am not opposed to drill-down either.
My main table is the summary and was hoping to show additional data when the user clicks on a Type. When clicked another table would be visible. For example, in the screenshot, the Pool table would be visible when the Pool type is clicked in the main report. As mentioned if this is easier as a drill-down then I will do that, but not sure how. The report currently has a dataset for each table. Do I need to combine the datasets to do a drill-down?
Main and child tables

The best way to accomplish what you described is with a drill down and you would need to combine the datasets into one.
Combine your datasets
Add a table to your report and reference the single dataset
Add your detail row group to the table - from your child table (Area, Average)
Add a parent group to your details row, group your detail row group by Type, it should add a Type column to your table. Delete this column and it will ask you to delete the associated group as well. Select the option to delete only the column.
Recreate your table by adding rows, be sure to match the grouping indicators (brackets) on the left side
Right-Click on the bottom row in the box where the bracket is to highlight the entire row, click Row Visibility. For the option "when the report is initially run:", select Hide. Check "Display can be toggled by this report item" and select the name of the textbox that contains [Type]. If you don't know what this is, exit out of the dialogue box and right-click on the cell [Type] and click Textbox properties, the Name will be in there
Repeat step 6 for the label row for your details row (second row from the bottom)

Related

Convert a specific cell into a column Power Query

I want to populate a new column with a specific cell using Power Query exactly like this:
from this -->to this
This task has been taught here: https://exceleratorbi.com.au/convert-a-cell-value-into-a-column-with-power-query/
but I start with a structured table within the worksheet and so the Power Query only reads the table, leaving out the specific cells that I need (which are B2 and B4), as displayed here.
Excel
Query
So how can I do the same thing?
Here is a complete example, starting with a worksheet like this:
Click on the specific cell containing the value with which you want to populate a new column (B2), enter a name in the name box (cellCategory), and press Enter. Right-click the cell and click on Get Data from Table/Range... which opens the Power Query Editor.
Open the Advanced Editor, delete everything, enter this line of code and click on Done:
Excel.CurrentWorkbook(){[Name="cellCategory"]}[Content][Column1]{0}
Named ranges that are loaded in Power Query are automatically transformed to a table. In the line above, [Column1]{0} accesses the value located in Column1 at row index 0 of that table which contains a single cell. So now you have a query that returns the content of that cell.
If your main table isn't yet loaded to Power Query, return to the worksheet, right-click on your table and click on Get Data from Table/Range....
Now, as shown in Step 5 of the linked tutorial, go to the ribbon tab Add Column, click on the button Custom Column, and add a new column named Category filled with the cellCategory query value by entering cellCategory and clicking on OK:
Here is the result:

Remove Tablix Static Columns Row Groups in SSRS

I have a report in SSRS that uses a matrix with static columns.
Here are the static columns:
After generating the report, the rows with same values end up being grouped together:
Is there any way to get rid of these groups? I'd rather the values be repeated for each row, so it looks more like an excel sheet.
Here is a better picture of my report design plus the row and column groups. These groups were created when I added them to the matrix and are not needed as far as what I can tell for my report:
As you are not doing any calcuations on hte row gorups, there is no need for them.
Delete all but one of the row groups by right-clicking the rowgroup in the Row Groups pane at the bottom of the screen and choosing Delete Group. If prompted, choose Delete Group Only, otherwise it will delete the associated columns too.
When you noly have one group left, right-click it and choose Group Properties and delete the group expression, this will change it to be a details style group.
Make sure the Hide Duplicate expression is back to default (blank or None) in case you changed it earlier.
That should work. I replicated a similar scenario to your and the above step did the trick.
You will probably also need to go back to your group properties and set the sorting options to ensure data is sorted correctly.

Oracle Apex 5.1: Report column based on LOV(List of values) showing returned value not display value

I have created an interactive report with a form. In the form I have two select lists. The first select list is a list of values defined in the shared component. And the second select list is another list of values which is also defined in the shared component but this select list populates its LOV based on the selected item in the first select list.
Let the names of the select lists are:
Region.
Country(which is dependent on the selected item in Region field).
Now when I press save/create button in the form, a row is created in the report. The Region column and Country column in the report are both "Plain Text(based on List of Values)". But what I see is the Region column is showing the correct display value of the LOV but the Country column is showing the returned value of the LOV.
I want both of these columns show the display values rather than the returned value. Could anyone help me find the solution?
Are you using the same LOVs in form and interactive report? If so and in the conditional LOV (countries) you refer your form item (ex. PX_REGION) it will not work correctly in IR. Probably IR is showing the returned value because the option "show extra values" is checked.
If this is the case my suggestion is to change your IR and instead of a "Plain Text(based on List of Values)" you make it plain text and change the query to an inline query in IR query to obtain the value you want to show.
If you don't want/like to put your LOV queries in different places I suggest you to use this approach shared by Nick Buytaert
Hope this helps you solve your problem.

How do I change the orientation of a table in a BIRT report

I need to change the orientation of a table in a BIRT report so that the table header is vertical instead of horizontal.
Is this possible? I don't want to use a Crosstab.
It seems this thread is still being pointed at so I posted an example of a horizontal table layout using a crosstab. I know it won't help the original author but others following this thread now may find this helpful.
To create the horizontal grouping, first create your query like normal, then create a Data Cube. In this data cube, drag each field that you want into a group. Then drag a new crosstab on the report and drag each field into the top right column group area. It will create a new header row for each field. Don't put anything in the left side (Rows) and don't put anything in the measure field (bottom-right). This will create labels on the left... and the data will extend out to the right.
The report design example can be downloaded from: http://developer.actuate.com/community/forum/index.php?/files/file/1079-horizontal-table-using-crosstab/
Virgil
If you want dataset records to be reported across the page, this would have to be done via a crosstab.
If you want dataset records to be reported down the page, this can't be done automatically as far as I know. However, it can be done by inserting a new detail line in your report table object for each database field to be reported, then moving column headings from the heading row into the first column's detail rows and moving record values into the second column's detail rows.
So, for example, a report with 6 columns in it would become a two column report with six detail rows.
Not in box (up to 3.7). You have to use 3'd party libs like that one.

How to populate dynamically generated select boxes with ajax

I haven't been able to find a solution for the particular problem I'm having with this project. I need to the following: dynamically add rows to a table that contain two select boxes AND use ajax to auto-populate the select options of the 2nd select box, based on the value of the first select box... in the respective table row (that was dynamically added on the fly by some js).
Still with me?
I can easily populate, dynamically, a select drop-down using ajax/javascript based on the value of the first drop-down, in the first row. I can even populate three or more select boxes in the same row, using ajax/js functions to load each additional select. Yet, this is not my goal.
Here's what I have... My form contains a simple table with 3 columns. First is a checkbox, the second is the "State" select box and the third column is the "City" select box. I have two buttons above the table that allow me to "Add Row" and "Delete Row". Mind you, the first row (which is programmed-in), works perfectly for loading the city names of a state using ajax.
Upon clicking the Add Row button, I'm able to create the second row dynamically, which contains the checkbox, state select and city select fields. The state select is populated based on the innerHTML content of the original column, but the city select is obviously null because it is expecting ajax to fill it. Note: the names and ID names of these fields are iterative... city_id, city_id_1, city_id_2, city_id_3 and so on... so I have that uniqueness to work with.
My problem lies in the fact that when I select a state from the 2nd or 3rd (and so on) rows, only the firstcity select changes. Why? Because the js/ajax processing function says to operate only on the element with name "city_id"!! Which is the name of the city select box in the first row.
I have not (yet) found a way to dynamically pass the name of the element I need updated to the onreadystate ajax function. When I've needed to populate two or three select boxes in a row (same row), I've had to have complementary ajax functions for each drop-down - which are static, mind you... but what if I create the element dynamically?? I can't pre-program that many functions into my page... or must I?
If you have any ideas on how to accomplish this I would be soo damn appreciative!!!
Thanks!
var i=1; // put here the number of the column being added now.
var x=document.getElementById("city_id_"+i);
// populate x

Resources