Skip to main content

Notifications

Finance | Project Operations, Human Resources, ...
Answered

Print SSRS dynamic query ranges on the report with simple query

Posted on by 104
I want to print the query ranges which are entered by a user when running a query based report. As I understood from Martins explanations in https://dev.goshoom.net/2014/09/showing-dynamic-parameters/ this could be easily done in the DP class of the report. So I want to try to switch to the data source type "Report data Provider" instead of "Query":
 
Im just struggeling how I should add the two different DataSets to the DataProvider Class:
1. Tmp Table with query ranges as explained in the blog
2. My simple query called "...InventTransListQuery" which could be adjusted by the user in the report dialog
 
Do I have to create a second tmp table for the result of the simple query even when the data is copied 1:1?
  • Verified answer
    Martin Dráb Profile Picture
    Martin Dráb 229,297 Most Valuable Professional on at
    Print SSRS dynamic query ranges on the report with simple query
    You'll indeed need a temporary table for the fields from InventTrans and InventTransOrigin that you're going to show in your report.
  • Basti Aurand Profile Picture
    Basti Aurand 104 on at
    Print SSRS dynamic query ranges on the report with simple query
    Any ideas on this?
  • Basti Aurand Profile Picture
    Basti Aurand 104 on at
    Print SSRS dynamic query ranges on the report with simple query
    Hi Layan,
     
    the report basis originally is only one dataset (-> Query with join: InventTrans and InventTransOrigin).
     
    Due to display the query range values, which are defined by the user on the query, the second dataset is needed (tmp table with query ranges as described in Martins blog post).
     
    Maybe you have a different solution?
  • Layan Jwei Profile Picture
    Layan Jwei 7,227 Super User 2024 Season 2 on at
    Print SSRS dynamic query ranges on the report with simple query
    Hi Basti,

    I'm not sure why you want two different datasets (can you please explain further)

    you just need a tmp table, query, controller class and RDP class (ui builder and contract are optional based on ur requirement)
    you just need to add [SRSReportQueryAttribute(queryStr(YourQueryName))] to your RDP class

    maybe check if this link helps
    https://medium.com/@RamzanLilla/how-to-create-ssrs-report-using-aot-query-in-dp-class-in-dynamics-365-fo-14f880b7e685
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Complete!

🔔 Be sure to subscribe to the new forums you are interested in to stay up to date! 🔔

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,900 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 229,297 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans