SSRS Report Generation From RDD

Hello.

I have an edited RDD that I would like to create a report from.

When I want to transform a BAQ into a report file I can edit in Microsoft Report Builder, I just use BAQ Report Designer. This creates an .rdl file that has all data sets and the query set up for me. → Is there a way to do this for an RDD? To me it looks like I will have to create a blank report and establish the data sets and query myself. Please tell me there is a much easier, faster way like there is with a BAQ.

Thank you.

I assume you used a preexisting RDD? If so, why not copy an RDL that already uses this RDD and edit to your liking?

It is a modified copy of the JobTrav RDD. It adds the bin/warehouse location of the part. It works successfully in a Crystal report, but I need an SSRS version.

Setting it up in a copy of Traveler .rdl produces an error in the system monitor.

Program Ice.Services.Lib.RunTask raised an unexpected exception with the following message: RunTask:
Ice.Core.SsrsReportService.ReportExecutionSoapException: Exception of type 'Ice.Core.SsrsReportService.ReportExecutionSoapException' was thrown.
SOAP Fault: An error has occurred during report processing. ---> Microsoft.ReportingServices.ReportProcessing.ProcessingAbortedException: An error has occurred during report processing. ---> Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Query execution failed for dataset 'JobHead'. ---> System.Exception: For more information about this error navigate to the report server on the local server machine, or enable remote errors)
Detail: <ErrorCode xmlns="http://www.microsoft.com/sql/reportingservices">rsProcessingAborted</ErrorCode><HttpStatus xmlns="http://www.microsoft.com/sql/reportingservices">400</HttpStatus><Message xmlns="http://www.microsoft.com/sql/reportingservices">An error has occurred during report processing.</Message><HelpLink xmlns="http://www.microsoft.com/sql/reportingservices">https://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Exceptions.ErrorStrings&amp;EvtID=rsProcessingAborted&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=15.0.1102.911</HelpLink><ProductName xmlns="http://www.microsoft.com/sql/reportingservices">Microsoft SQL Server Reporting Services</ProductName><ProductVersion xmlns="http://www.microsoft.com/sql/reportingservices">15.0.1102.911</ProductVersion><ProductLocaleId xmlns="http://www.microsoft.com/sql/reportingservices">1033</ProductLocaleId><OperatingSystem xmlns="http://www.microsoft.com/sql/reportingservices">OsIndependent</OperatingSystem><CountryLocaleId xmlns="http://www.microsoft.com/sql/reportingservices">1033</CountryLocaleId><MoreInformation xmlns="http://www.microsoft.com/sql/reportingservices"><Source>Microsoft.ReportingServices.ProcessingCore</Source><Message msrs:ErrorCode="rsProcessingAborted" msrs:HelpLink="https://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Exceptions.ErrorStrings&amp;EvtID=rsProcessingAborted&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=15.0.1102.911" xmlns:msrs="http://www.microsoft.com/sql/reportingservices">An error has occurred during report processing.</Message><MoreInformation><Source>Microsoft.ReportingServices.ProcessingCore</Source><Message msrs:ErrorCode="rsErrorExecutingCommand" msrs:HelpLink="https://go.microsoft.com/fwlink/?LinkId=20476&amp;EvtSrc=Microsoft.ReportingServices.Exceptions.ErrorStrings&amp;EvtID=rsErrorExecutingCommand&amp;ProdName=Microsoft%20SQL%20Server%20Reporting%20Services&amp;ProdVer=15.0.1102.911" xmlns:msrs="http://www.microsoft.com/sql/reportingservices">Query execution failed for dataset 'JobHead'.</Message><MoreInformation><Source></Source><Message>For more information about this error navigate to the report server on the local server machine, or enable remote errors</Message></MoreInformation></MoreInformation></MoreInformation><Warnings xmlns="http://www.microsoft.com/sql/reportingservices" />)
   at Ice.Core.SsrsReportService.ReportExecutionService.SetExecutionParameters(ParameterValue[] parameters, String parameterLanguage) in C:\_releases\ICE\ICE4.2.100.9\Source\Shared\Lib\ReportingServices\ReportExecutionService.cs:line 189
   at Ice.Core.SsrsReporting.SsrsRendererBase.ConfigureReportServerForReport(String reportPath, ParameterValue[] parameters) in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\SsrsReporting\SsrsRendererBase.cs:line 169
   at Ice.Core.SsrsReporting.SsrsSingleDocumentRenderer.<>c__DisplayClass1_0.<RenderDocument>b__0() in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\SsrsReporting\SsrsSingleDocumentRenderer.cs:line 49
   at Ice.Core.SsrsReporting.SsrsRendererBase.TraceReportRendered(String printProgram, String ssrsRenderFormat, Func`1 timedAction) in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\SsrsReporting\SsrsRendererBase.cs:line 0
   at Ice.Core.SsrsReporting.ReportProcessorBase.RenderReport(String ssrsRenderFormat, String printProgram, Boolean ignorePageSettings) in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\SsrsReporting\ReportProcessorBase.cs:line 0
   at Ice.Core.SsrsReporting.ReportProcessorBase.RenderReportForPreviewOrGenerate(RenderedSsrsReport renderedReport) in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\SsrsReporting\ReportProcessorBase.cs:line 422
   at Ice.Core.SsrsReporting.ReportProcessorBase.ProcessReportPart(String reportLocation) in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\SsrsReporting\ReportProcessorBase.cs:line 163
   at Ice.Core.SsrsReporting.StandardReportProcessor.ProcessReportParts() in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\SsrsReporting\StandardReportProcessor.cs:line 34
   at Ice.Core.RoutingAndBreaking.ReportPersister.Persist(ReportInstanceInformation reportInstance, Func`2 reportsRenderer, Action`1 fillSysRptLstRow, Action`2 processReport, Func`3 filterTableAttachmentsFunc) in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\RoutingAndBreaking\ReportPersister.cs:line 58
   at Ice.Core.RptBase.ReportSsrsDatabaseBuilder.RenderUnroutedSsrsReport() in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\RptBase\ReportSsrsDatabaseBuilder.cs:line 359
   at Ice.Core.RptBase.ReportDatabaseBuilder.XMLClose() in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\RptBase\ReportDatabaseBuilder.cs:line 93
   at Ice.Core.RptTaskBase`1.XMLClose() in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Internal\Lib\TaskLib\RptBase\RptTaskBase.cs:line 260
   at Erp.Internal.JC.JobTrav.RunProcess(Int64 instanceTaskNum, String outputFileName) in C:\_releases\ERP\ERP11.2.100.0\Source\Server\Internal\JC\JobTrav\JobTrav.cs:line 579
   at Ice.Hosting.TaskCaller.InnerExecuteTask(IceDataContext newContext) in C:\_releases\ICE\ICE4.2.100.9\Source\Server\Framework\Epicor.Ice\Hosting\TaskCaller\TaskCaller.cs:line 68
   at Ice.Hosting.TaskCaller.ExecuteTask() in C:\_releases\ICE\ICE4.2.100.9\Source\Server\Framework\Epicor.Ice\Hosting\TaskCaller\TaskCaller.cs:line 64
   at Ice.Lib.RunTask.BpmFriendlyTaskLauncher.Run(String sessionIdPrefix, IceContext db, Action taskRunner) in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Services\Lib\RunTask\BpmFriendlyTaskLauncher.cs:line 63
   at Ice.Services.Lib.RunTaskSvc.InnerRunTask(Int64 ipTaskNum, Boolean suppressTransaction) in C:\_releases\ICE\ICE4.2.100.0\Source\Server\Services\Lib\RunTask\RunTask.cs:line 450

Copy the Job Traveler with report style maintenance and then change the Data Definition to point to your customized RDD.

1 Like

Are you reaching directly into the production database? I would have expected the table to say, “JobHead_”

Copy the Job Traveler with report style maintenance and then change the Data Definition to point to your customized RDD.

That is what I did for this.

Are you reaching directly into the production database? I would have expected the table to say, “JobHead_”

I am not sure. I did not do the modification of this RDD myself. Why would that cause an issue for the SSRS version but not the Crystal?

Second time today I get to share this link!

Let’s talk about SSP (server-side printing) - Experts’ Corner - Epicor User Help Forum

So that is how it works. In your SSRS report, Kinetic is creating tables of the exported report data keeping the same table names but appending the GUID for that particular run. If you look at your SQL expression in your RDL, you will see things like “…FROM JobHead_” + Parameters!TableGuid.Value + "…

If your SQL is querying JobHead without the _GUID, it won’t find that table since the exported data is in another database altogether separate from your production/test/pilot data.

I’m only suggesting this because of the error message indicating JobHead and not a longer table name with the GUID at the end. Can you post the Data Set query expression?

image

2 Likes

Thank you for the link.

I only know how to access the data set expression via the .rdl report in Microsoft Report Builder. I don’t know how to peer into the Crystal one that uses the modified RDD. We don’t even have SAP or anything. Is there a way?

Otherwise, I would just be showing you the normal out of box data set expression.

(Something tells me if they went through all this workaround then there is a lot of difficulty in adding the Bin location…)

Let me upload the modified RDD so at least you can have that to look at it and it might tell you something.:

RDDSHIJT.xml (676.5 KB)

Oh, this is the Report Data Definition. I’m looking for your SSRS report.

If you run the report and archive the report for a day or more, you can download the XML the ReportDataDef created. That file is brought down to the client and the Crystal Runtime reads it and prepares the report locally. It’s a totally different paradigm. I’d like to see the RDL.

I think I am missing a big step here…

So right now I just have a straight copy of the out of box Traveler I am trying to use the modified RDD with. I would hate to have to rebuild the whole thing manually just to add in a Bin location. This is what is inside the only data set in the .rdl (JobHead):

=“SELECT T1.DueDate,T1.IUM,T1.ProdQty,T1.ReqDueDate,T1.StartDate,T1.Calc_MultiJobParts,T1.Calc_OrderQty,T1.Calc_StockQty, T2.AssemblySeq,T2.BomSequence,T2.Company,T2.[Description],T2.DrawNum,T2.IUM as JobAsmbl_IUM,T2.JobNum,T2.OverRunQty,T2.PartNum,T2.PullQty,T2.RequiredQty,T2.RevisionNum,T2.Calc_BCAsmSeq,T2.Calc_BCJobNum,T2.Calc_BCPartNum,T2.Calc_BCRevNum,T2.Calc_comment, T2.Calc_AttributeSetShortDescription, T3.CommentText,T3.Instructions,T3.DaysOut,T3.DueDate as JobOper_DueDate,T3.EstProdHours,T3.EstSetHours,T3.Machines,T3.OpCode,T3.OpDesc,T3.OprSeq,T3.PrimaryProdOpDtl,T3.PrimarySetupOpDtl,T3.ProdStandard,T3.RunQty,T3.StartDate as JobOper_StartDate,T3.StdFormat,T3.Calc_BCOpCode,T3.Calc_BCOprSeq,T3.Calc_DispStatus,T3.Calc_OPText,T3.Calc_OPType,T3.Calc_PurPoint,T3.Calc_VendorId,T3.Calc_VendorName,T3.OpCode_OpDesc, T4.CapabilityID,T4.ConcurrentCapacity,T4.DailyProdRate,T4.OpDtlSeq,T4.ProdCrewSize,T4.ResourceGrpID,T4.ResourceID,T4.SetUpCrewSize,T4.SetupOrProd,T4.Calc_BCCapabilityID,T4.Calc_BCResGrpID,T4.Calc_BCResourceID,T4.Calc_CapbltyDesc,T4.Calc_ResDesc,T4.Calc_ResGrpDesc,T4.Calc_SchedResDesc,T4.Calc_SchedResGrpDesc,T4.Calc_SchedResGrpID,T4.Calc_SchedResID, T5.ResourceGrpID as ResourceTimeUsed_ResourceGrpID,T5.ResourceID as ResourceTimeUsed_ResourceID,T5.WhatIf
FROM JobHead_” + Parameters!TableGuid.Value + " T1
LEFT OUTER JOIN JobAsmbl_" + Parameters!TableGuid.Value + " T2
ON T1.Company = T2.Company AND T1.JobNum = T2.JobNum
LEFT OUTER JOIN JobOper_" + Parameters!TableGuid.Value + " T3
ON T2.Company = T3.Company AND T2.JobNum = T3.JobNum AND T2.AssemblySeq = T3.AssemblySeq
LEFT OUTER JOIN JobOpDtl_" + Parameters!TableGuid.Value + " T4
ON T3.Company = T4.Company AND T3.JobNum = T4.JobNum AND T3.AssemblySeq = T4.AssemblySeq AND T3.OprSeq = T4.OprSeq
LEFT OUTER JOIN ResourceTimeUsed_" + Parameters!TableGuid.Value + " T5
ON T4.Company = T5.Company AND T4.JobNum = T5.JobNum AND T4.AssemblySeq = T5.AssemblySeq AND T4.OprSeq = T5.OprSeq AND T4.OpDtlSeq = T5.OpDtlSeq"

What is the table and field name for the bin that you’re trying to add?

It looks like they added this:

image

When I check out the bin table in Warehouse Bins Maintenance with the help, though, this is what I get:

image

OK, the plot thickens. If you’re looking for the PrimBin, that is indeed in PlantWhse because a part can have a different Primary Bin in each warehouse.

You don’t indicate which version of Kinetic that you’re on. I get an error when I try to import your RDD. Can you explain what the Crystal report did without using technical terms? Adding primary bin to the finished part? Each Job Material?

Once that is sorted. You’ll need to update the SQL in your RDL to grab the PrimBin field and then add it to the Fields. There is a lot of documentation to do this but it all builds on previous steps working.

Can you explain what the Crystal report did without using technical terms? Adding primary bin to the finished part? Each Job Material?

I will do my best.

It took the main Part number and provides the code of the Primary Bin of that particular part number.

Here is the default SSRS report:

This is what the Crystal one looks like:

That is the only thing I need.:

Ah, so the material movers know where to send the finished part. Do you only have one Warehouse then? If not, what did the Crystal Report do?

Coming in late… but I see the added PlantWhse in your RDD:

image

But I don’t see it being referenced as a new table join in your RDL query. I know you said the below was the “out-of-the-box query”… so you’d have to add the bold text below:

NOTE!
Make sure there is a SPACE at the end of the previous line (following T5.OpDtlSeq

Then, higher up in the query, you can add T6.PrimBin as a field in your query expression.

You’d also have to add PrimBin as a “query field” as well, then you can add it into your report.

POTENTIAL GOTCHA…. I know you have a custom RDD… just verify PartNum is not excluded on JobHead, because it IS by default. Since it is “excluded” by default, you won’t be able to use it in a relationship. But again, that may have already been accounted for by the previous Crystal requirements.

image

2 Likes

Hello!

Sorry for the delay. I wanted to confirm some information and look into the Crystal report itself.

Ah, so the material movers know where to send the finished part. Do you only have one Warehouse then? If not, what did the Crystal Report do?

We have multiple warehouses, but I think the people using it only rely on one. I asked one of our users to explain what happens: “Parts go to the default bin in the part master, under warehouse, primary bin and they backflush from the default bin (based on when the job was cut).”

Here is the Crystal report:
JobTravBin.rpt (38 KB)

But I don’t see it being referenced as a new table join in your RDL query. I know you said the below was the “out-of-the-box query”… so you’d have to add the bold text below:

I did as you recommended and got an “The CommandText expression for the query ‘JobHead’ contains an error: [BC30205] End of statement expected.” error when saved. I probably did it incorrectly…:

="SELECT T1.DueDate,T1.IUM,T1.ProdQty,T1.ReqDueDate,T1.StartDate,T1.Calc_MultiJobParts,T1.Calc_OrderQty,T1.Calc_StockQty, T2.AssemblySeq,T2.BomSequence,T2.Company,T2.[Description],T2.DrawNum,T2.IUM as JobAsmbl_IUM,T2.JobNum,T2.OverRunQty,T2.PartNum,T2.PullQty,T2.RequiredQty,T2.RevisionNum,T2.Calc_BCAsmSeq,T2.Calc_BCJobNum,T2.Calc_BCPartNum,T2.Calc_BCRevNum,T2.Calc_comment, T2.Calc_AttributeSetShortDescription, T3.CommentText,T3.Instructions,T3.DaysOut,T3.DueDate as JobOper_DueDate,T3.EstProdHours,T3.EstSetHours,T3.Machines,T3.OpCode,T3.OpDesc,T3.OprSeq,T3.PrimaryProdOpDtl,T3.PrimarySetupOpDtl,T3.ProdStandard,T3.RunQty,T3.StartDate as JobOper_StartDate,T3.StdFormat,T3.Calc_BCOpCode,T3.Calc_BCOprSeq,T3.Calc_DispStatus,T3.Calc_OPText,T3.Calc_OPType,T3.Calc_PurPoint,T3.Calc_VendorId,T3.Calc_VendorName,T3.OpCode_OpDesc, T4.CapabilityID,T4.ConcurrentCapacity,T4.DailyProdRate,T4.OpDtlSeq,T4.ProdCrewSize,T4.ResourceGrpID,T4.ResourceID,T4.SetUpCrewSize,T4.SetupOrProd,T4.Calc_BCCapabilityID,T4.Calc_BCResGrpID,T4.Calc_BCResourceID,T4.Calc_CapbltyDesc,T4.Calc_ResDesc,T4.Calc_ResGrpDesc,T4.Calc_SchedResDesc,T4.Calc_SchedResGrpDesc,T4.Calc_SchedResGrpID,T4.Calc_SchedResID, T5.ResourceGrpID as ResourceTimeUsed_ResourceGrpID,T5.ResourceID as ResourceTimeUsed_ResourceID,T5.WhatIf,T6.PrimBin
 FROM JobHead_" + Parameters!TableGuid.Value + " T1
 LEFT OUTER JOIN JobAsmbl_" + Parameters!TableGuid.Value + " T2
  ON T1.Company = T2.Company AND T1.JobNum = T2.JobNum
 LEFT OUTER JOIN JobOper_" + Parameters!TableGuid.Value + " T3
  ON T2.Company = T3.Company AND T2.JobNum = T3.JobNum AND T2.AssemblySeq = T3.AssemblySeq
 LEFT OUTER JOIN JobOpDtl_" + Parameters!TableGuid.Value + " T4
  ON T3.Company = T4.Company AND T3.JobNum = T4.JobNum AND T3.AssemblySeq = T4.AssemblySeq AND T3.OprSeq = T4.OprSeq
 LEFT OUTER JOIN ResourceTimeUsed_" + Parameters!TableGuid.Value + " T5
  ON T4.Company = T5.Company AND T4.JobNum = T5.JobNum AND T4.AssemblySeq = T5.AssemblySeq AND T4.OprSeq = T5.OprSeq AND T4.OpDtlSeq = T5.OpDtlSeq"
 LEFT OUTER JOIN PlantWhse_" + Parameters!TableGuid.Value + " T6 
  ON T1.Company = T6.Company AND T1.PartNum = T6.PartNum"

You have quotation marks at the end of your T5 table join… which SQL thinks is ending the query. Since you added a line after that, you need to replace those quotation marks with a space… and move the quotes to the end (which appears you already have a set at the end, so you’re good there). So, in your query, just change T5.OpDtlSeq” to… T5.OpDtlSeq (with a space at the end).

Again, If you just delete them, you may also get another error. You need a space after T5.OpDtlSeq.

1 Like

This sounds like a hard-learned lesson from time spent looking for a missing space.