Skip to main content

Notifications

Customer experience | Sales, Customer Insights,...
Unanswered

What should I do to get only related records in SSRS Report

Posted on by 55

Hi Gents,

I have created SSRS Report and uploaded into CRM.

It is showing all data from the system even I have chosen to display "Forms for related record types".

I am updating below the SQL Query which the datasets has been taken.

Help me to get only related data in SSRS Report.

pastedimage1596021157308v1.png


SELECT

Filteredibs_goodrequisition.ibs_reqdate AS GRS_Date, Filteredibs_goodrequisition.ibs_customername AS Customer,
Filteredibs_goodrequisition.createdbyname AS Req_by, Filteredibs_goodrequisition.ibs_tousername AS To_custody,
Filteredibs_goodrequisition.ibs_name AS GRS_Ref, Filteredibs_goodrequisition.ibs_fromwhname AS From_wh,
Filteredibs_goodrequisition.ibs_towhname AS Deliver_to, Filteredibs_goodrequisition.ibs_closingdate AS Closing_Date,
Filteredibs_goodrequisition.ibs_invoiceno AS Invoice_No, Filteredibs_goodrequisition.ibs_purpose AS Purpose,
Filteredibs_goodrequisition.ibs_salessupervisorname AS Sales_Sup, Filteredibs_goodrequisition.ibs_servicesupervisorname AS Service_Sup,
Filteredibs_grsproducts.ibs_productname AS Description, Filteredibs_grsproducts.ibs_qty AS Qty, Filteredibs_grsproducts.ibs_unitname AS Unit,
Filteredibs_grsproducts.ibs_remarks AS Remarks,
FilteredProduct.productnumber as Part_No


FROM FilteredProduct RIGHT OUTER JOIN
Filteredibs_grsproducts ON FilteredProduct.productid = Filteredibs_grsproducts.ibs_product RIGHT OUTER JOIN
Filteredibs_goodrequisition ON Filteredibs_grsproducts.ibs_grsid = Filteredibs_goodrequisition.ibs_goodrequisitionid

  • a33ik Profile Picture
    a33ik 84,323 Most Valuable Professional on at
    RE: What should I do to get only related records in SSRS Report

    Hello,

    You should use prefiltering. In your case query should look like

    SELECT

    CRMAF_ibs_goodrequisition.ibs_reqdate AS GRS_Date, CRMAF_ibs_goodrequisition.ibs_customername AS Customer,

    CRMAF_ibs_goodrequisition.createdbyname AS Req_by, CRMAF_ibs_goodrequisition.ibs_tousername AS To_custody,

    CRMAF_ibs_goodrequisition.ibs_name AS GRS_Ref, CRMAF_ibs_goodrequisition.ibs_fromwhname AS From_wh,

    CRMAF_ibs_goodrequisition.ibs_towhname AS Deliver_to, CRMAF_ibs_goodrequisition.ibs_closingdate AS Closing_Date,

    CRMAF_ibs_goodrequisition.ibs_invoiceno AS Invoice_No, CRMAF_ibs_goodrequisition.ibs_purpose AS Purpose,

    CRMAF_ibs_goodrequisition.ibs_salessupervisorname AS Sales_Sup, CRMAF_ibs_goodrequisition.ibs_servicesupervisorname AS Service_Sup,

    Filteredibs_grsproducts.ibs_productname AS Description, Filteredibs_grsproducts.ibs_qty AS Qty, Filteredibs_grsproducts.ibs_unitname AS Unit,

    Filteredibs_grsproducts.ibs_remarks AS Remarks,

    FilteredProduct.productnumber as Part_No

    FROM FilteredProduct RIGHT OUTER JOIN

    Filteredibs_grsproducts ON FilteredProduct.productid = Filteredibs_grsproducts.ibs_product RIGHT OUTER JOIN

    Filteredibs_goodrequisition CRMAF_ibs_goodrequisition ON Filteredibs_grsproducts.ibs_grsid = CRMAF_ibs_goodrequisition.ibs_goodrequisitionid

    Just the update of existing report will not help in your case. Drop the report from CRM and recreate it with updated query.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,240 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans