We implemented a new system. Read-only access to the database. Writing reports for current and historical data. Using drill through report to display location and number of people there. Select the count of the location and go to details.
I query the location table to populate a parameters values. This works properly.
What I want is to ADD "Pre-Implementation" to the Parameters result set to cover the NULLS that exist because the data was before the implementation date. The phrase needs to appear in the drop-down list of locations so the user can select it. The phrase listed above needs to appears on the report. How would you do this?
What I have tried:
Have query that returns "Pre-Implementation" along with active locations for the time period. SSRS will not display as a choice in a drill through report.
Related
I'm trying to figure out a way to dynamically create a report summary that lists the totals of instances for each account dynamically at the beginning or end of the report. An account will only show up on the report if that account had any instances in the date/time range established by the Start/End date parameter fields, so every account will not always show, hence the dynamic part of the problem. There is surprising sparse information on how to do this from what I've found. Any ideas would be appreciated.
Use Insert, CrossTab...
Select Account as the row and select the value you wish to summarize.
There are many other options if you look into CrossTab features...
I am designing a report in IBM Cognos Report Studio 10.2.2 that includes a list of different types of disabilities and the count of employees that have each type of disability. However, this list is only supposed to display if there are at least 10 employees with some kind of disability.
I tried solving this problem by creating a separate query (Disability summary) with a data item (Disabled) where each employee gets a 1 if they have a disability and 0 otherwise. I then added another data item (Number disabled) that I define as:
total([Disabled]) for report
I then create a Boolean variable in the Condition Explorer (Disabilities Reportable) which I define as:
[Disability Summary].[Number disabled] >= 10
Next, for the list that displays the count for each type of disability, I set the Render Variable to Disabilities Reportable. I also place a singleton elsewhere on the report page and set the query to Disability Summary and check Number disabled as a property. I also insert the Number disabled data item in the singleton.
However, when I run the report, I get the following RSV-VAL-0032 error:
The following expression is not valid: [Disability Summary].[Number disabled] > = 10.
If the item exists in a query but is not referenced in the layout, add it to a property
list. CRX-API-0005 An error occurred at or near the position '0'. The variable named
'[Disability Summary].[Number disabled]' is invalid.
Render Variables need to be accessible to the Page where they are used. If it works in a Report Expression, it will work in a Render Variable.
This means you must use prompt variables, built in Report Functions, or the query that is tied directly to the Report Page.
Assign the query that you are pulling your disability count from to the Report Page, then set the disability count field as a 'Property'. This makes the field accessible to the report for formatting and Report Expressions.
Click anywhere in your report, then on the properties panel click the Up Arrow to drill up the the very top, the 'Page' level. (Alternatively, Page Explorer->Report Pages->Double Click the Page you are working on)
Define the 'Query' and 'Properties'.
Creating a separate summary query is perfectly acceptable. If your summary is at a different aggregate level than the details of your list, Cognos is going to create a separate query and make separate database trips anyway. Use whatever method works and makes sense for you.
I am still fairly new to SSRS, and I do not know what I need to/can provide as examples to help clarify my issue.
I am developing an SSRS report that accesses a NAV database and generates a report for an equipment number. My task is to generate a master report that can print multiple of those kind of reports(currently 10 max). I am using sub-reports to get the content that I need for an equipment number.
I am looking for a way to make this dynamic, where I can generate 1 to n sub-reports based on how many values were picked for the multi-value parameter. The end result should be one PDF file that contains the full report for each equipment number listed. I am trying to only use SSRS.
I have seen where I could hide sub-reports then make them visible if a condition is met, but this isn't the functionality that I am looking to use. So, what would be the best way to dynamically generate sub-reports based on a multi-value parameter?
I figured it out. I made the sub-report parameter equal no value. I made the main report with a parameter that can select multiple equipment numbers, a list, and a data set which filtered down to the appropriate equipment numbers to avoid duplication. I made the sub-report object in the main take in the cell value from the list equipment number. When the list proceeded to the next row, it copied all of the objects in the box area.
I have a VB active report which has many different attributes. The report contains attributes area, balance, id and status and is currently grouped my area. What I need to do now is remove all lines from the report where the balance is equal to 0 and the status equal to deactive. The information for the active report is from my database. Thus I think the best way would be to only select records where the balance is not 0 and status not equal to deactive. Is there a way I can query my database and have the active report be based off the query results? Is there an easy way to do this? Thanks for any help.
Yes, the best way to do this is to change the query so that only the minimum records you need are actually coming into the report. The Modify Data Sources at Run Time topic from the documentation shows how to modify that SQL statement in the code dynamically at runtime.
If you can hard-code the SQL query for the report you should probably just modify the SQL at design time inside the designer. This Bind Reports to a Data Source topic shows you how to do that.
You can also programatically control the visibility of fields/textboxes based on the data using the Format event of the section containing those controls (most likely Detail_Format), but it sounds to me like modifying the SQL query is your best bet.
I am working on Windows Forms Projects.
I am creating a report for customers.
The report data is pulled from a "CustomerDetails" table.
A field in the table is called "CustPhotoName", this holds a string which relates to an image file.
I Currently have a report set up which runs for a single customer by passing in a customer ID. Then using the passed in ID to populate a Dataset with an ImageRow and then a sub report with the image from the dataset.
I am wanting to set up this report where I can pass in an array of customer IDs and produce the reports (1 page per customer with image (if CustPhotoName has value))
Please can someone let me know how is the best way to do this for the multiple customers.
Add a CustomerID parameter to the report. Type Number. Set it to allow multiple values. In the report's record-selection formula, add the following:
AND {table.customer_id} IN {?CustomerID}
You probably want to group the report by {CustomerID} as well. In the group's footer, select Section Expert and check New Page After. This way each customer will start on a new page.