I'm creating a report which is scoped to individual record level for Service Cases in Dynamics CRM 2011.
This report has 4 datasets; 1. Filter, 2. TicketDetails, 3. Materials and, 4. Labour.
The Filter dataset is there to grab the IncidentId of the current service case being viewed in CRM.
SELECT IncidentId FROM FilteredIncident AS CRMAF_FilteredIncident
I have a parameter called incidentfilter, it's source is the Filter dataset. CRM seems to be ignoring the CRMAF_ prefix and just returning all service cases.
Datasets 2 and 4 are both have a where clause to filter on the incidentfilter parameter value. Dataset 3, queries GP, for that I pass in the TicketNumber field from the service case.
My report seems to be running, it's just that it retrieves every service case from CRM.
I've had similar problem with CRM ignoring the CRMAF_Prefix. You can try this:
Just to make sure, do you have more than one table you are trying to apply the CRMAF_prefix on? If you have, make sure you limit the number of tables to just one.
You could try to add the CRMAF_prefix to the fields as well:
SELECT CRMAF_FilteredIncident.IncidentId FROM FilteredIncident AS CRMAF_FilteredIncident
Related
First time posting here so please be kind.
I've come from using PowerBI to achieve pretty much everything I need to with a couple of clicks to using SSRS 2008... and I'm having a hard time. Here's what I'm trying to do:
I have a main report that summarizes some data on how long it takes to close down help desk tickets. On that report I have a table with summary figures (ie 220 tickets were picked up after 5 working days, 18 tickets were reopened etc). I want to click the text-box that contains 220 and be taken to a drillthrough report that contain the same table with column headers and just different row sets in each case. There will be 8 drill through actions in total and I currently have 8 drill through reports. Only 2 of those are parameter based, the others just filter the dataset based on some conditions.
What I'm trying to work out is this: can my 8 drill-through reports be rolled into one, if they're just different views of the same dataset? I've created some calculated columns with values (Yes/No because boolean doesn't allow multiple values) which are easier to pass to parameters. I also have 8 parameters on my detail data set. I've set up actions (where parameter1 = yes for instance) to take me to my detail report and use the corresponding parameter each time. It should work... but it doesn't and I can't work out why. Currently its' complaining that I can't compare a boolean to an int16 - neither the value in my calculated column nor the default parameter value is boolean or int. So, am I trying to do something that just isn't possible? Has anyone else achieved this?
Edit: here's the parameter
The error I'm getting is
The calculated column that should be checked against the parameter is
=IIF(IsNothing(Fields!DatePickedUpByAgent.Value), "Yes", "No").
Here's how I defined the action to take me to the drill through report in this case
Here are the filters on the subreport dataset based on the parameters passed through from the main report. "NotYetPickedUpByAgent" is the example we've been discussing here. enter image description here
Could you please go through each of your parameters one by one.
I would suggest deleting all the filters and trying to run the report and subreport.
Then keep adding filter one by one.
I think issue can be any of the filter and not the one you think.
I have a query that returns relevant data about inspectors and how long it takes them to respond to issues. The only parameters are a BeginDate and EndDate so for any given date range there could be anywhere from 0 to 100 inspectors.
I am using only one dataset and it contains an "Inspector" field that I'm hoping can be used as a filter to create as many tables as there are inspectors.
I know you can set filters on tables but from my (limited) SSRS knowledge, you must already have the tables created and the filters are typically hard-coded. What I need, is some way for the report to see how many Inspectors there are in the dataset and group those records into their own tables, repeating the same one created tablix over and over as needed.
This is being done strictly in SSRS 2012, not using a ReportViewer where back-end code could help me out unfortunately...
I don't have any code examples to provide, like I said I know you can do filtering but I am at a loss when it comes to doing something like this dynamically based on data... Sorry.
Depending on the report design you could either...
Single report with grouping
1. Create a single tablix.
2. Create a row group by Inspector and then add whatever fields you need to the details section.
3. You can optionally set page breaks between instances of your Inspector rowgroup from the rowgroup properties.
Sub report method
1. Create a subreport that accepts a parameter (InspectorID for example).
2. In the subreport filter the dataset using the parameter passed in so it only return data for a single inspector.
3. Add whatever controls you need to the report to handle a single Inspector
4. Create a main report
5. Add a dataset that gives you a simple distinct list of Inspectors, this will be used to pass parameters to the subreport.
Lets assume it just contains a list of InspectorIDs.
6. Add a list control to the report and set it's dataset property to the dataset that contains your list of InspectorIDs
7. Right-click in the list control's 'cell' and insert a subreport.
8. Set the subreport property to the subreport you created earlier and set that parmameter IsnpectorID to your InpsectorID field.
This will produce a subreport for each instance of inspector it finds.
Sorry about the format of this answer, in a rush!
I've started using SSRS for 6 month and trying to setup a data driven report where the parameter in the report may contain multiple values (customer numbers).
Ive tried to follow the guideline from microsoft:
https://social.msdn.microsoft.com/Forums/sqlserver/en-US/3b0f1620-a7ac-4edd-a577-4beef4bddb14/forum-faq-how-to-configure-a-data-driven-subscription-which-get-multivalue-parameters-from-one?forum=sqlreportingservices#3b0f1620-a7ac-4edd-a577-4beef4bddb14
The parameter in the report is setup following the guideline:
uncheck “Allow multiple values” option for the parameter
check "none" on available values
check "none" on default values
The dataset properties for the parameter are setup by adding a filter:
CustomerKey in split(Parameters!Customer.Value, ",")
The report is working fine when there is only one customer in the subscription table but report is empty when the number of customer are more than one.
The data set of the report is not changed. The query of the data subscription is retrieving the data from the SQL table where I have stored the emails and customer number are related. The data tables looks like this:
The tabel is formatted in this way:
The query in the subscription using the table looks like this:
SELECT *
FROM [Table_Archive].[dbo].[ReportSubscription]
where ReportName='CustomerOrder' and Schedule='Every day'
The data retreived to be used in the report is defined by the following query:
select
CustomerLabel AS CustomerLabel
, CustomerKey AS CustomerKey
, SalesItemKey AS SalesItemKey
, SalesItemName AS SalesItemName
, SalesOrderDetailNumberKey
From factview.SalesOrder
where CustomerKey in (#Customer)
I've tried multiple solution on how to specify the customer number in the table (',';"," etc) but without success. I'm quite uncertain if the approach that i'm trying will ever work and i'm having difficulties in finding any good suggestions, hence this post.
I am using SSRS 2012.
I have two datasets. I have two tables.
The first table contains a contract Id which is used as parameter in the second dataset.
I want to set the parameter as the contractId (ie Fields!ContractId.Value, or ReportItems!Contract1.Value) or something like that but nothing works because of different limitations.
If I would be using a subreport that would have been easy just pass the Field!Contract.Value from the 1st dataset as the parameter for the second and there you go. But since we want to call the report using SQL server agent, I cannot use subreport since the agent is limited and does not accept subreport.
So I believe my only option is to use two different tables, but I still need the value from the first dataset. Also, I don't think LookUp() would work for me as I do not have Ids.
Does anyone already did something like that?
Thanks for any help.
You can create report parameters in which the available values are pulled from a query.
Then just use the parameter in your second data set.
I have created a complex report in Microsoft Business Intelligence.
The report has its own (fairly complex) WHERE clause. Is it possible for the user to set the CreatedOn date as part of the criteria?
UPDATE
I was looking at this again. On a basic report (one table) if i import the report over one created with the report wizard, this give you the filter options and works.
On the more complex report that uses the union statement to pull data out of two tables the filter options are available however they have no effect, this is after removing the where clause.
END UPDATE
Thanks
Luke
I have been doing some research into this topic, and it appears that if you alias the fields and prefix them with CRMAF_ this allows you to add filtering. I'm going to look at this over the next few days and see how it works. However it has been noted that several people have been unable to get this to work correctly.
Please note you need to prefix both the table and fields.
You then can set the filter.