Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Unable to get the GUID of current record via SSRS Report run from a record using CRMAF_

Posted on by 1,579

I am encountering a strange problem with CRM 2011 that should not be happening.

I have an SSRS Report with the following query:

SELECT new_s_batchmanagementid [BatchID]
FROM filterednew_s_batchmanagement AS CRMAF_filterednew_s_batchmanagement

My understanding is that this query is supposed retrieve the GUID for the specific record that is opened in the form where this report is run from.

My expectation is that when I run this report from within the new_s_batchmanagement form on a specific new_s_batchmanagement record, I will get back the GUID of the record in which I am running it.

The specific record shown below, has a GUID of 59CA9DB0-5CD7-E611-AE66-000C29D70C71 - that is what I expect to get back

2474.IMG1.png

However,  I don't get that back and instead I get back the GUID that corresponds to the very first new_s_batchmanagement  record I entered in CRM whose GUID is B5830132-88D6-E611-9362-000C29D70C71

This is a problem because I am unable to run a report on the currently open record if I cannot even get the GUID for that currently open record.

I have never experienced this issue before, so clearly something is terribly wrong.

My other reports that do get the GUID for the currently open record look identical to this.

I set this up so it is related to Forms for related record types as shown below.

RPT1.png

I don't understand why this one is getting the first entered GUID instead of the GUID for the current record from where the report is being run.

The only thing that's changed since I last wrote something like this is that hundreds of Windows Server, SQL, and CRM Updates and Service Packs have been applied.

Any help would be greatly appreciated.

*This post is locked for comments

  • Verified answer
    ACECORP Profile Picture
    ACECORP 1,579 on at
    RE: Unable to get the GUID of current record via SSRS Report run from a record using CRMAF_

    I got around the issue by using a parent/child report and sub-report. That works as expected.

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!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans