Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 Community / Forums / Finance forum / Exception occurred on ...
Finance forum

Exception occurred on the metadata service on client or server - error

(0) ShareShare
ReportReport
Posted on by 15

Hi experts,

Please help me in solving this error I get while selecting a Query for a  SSRS report's dataset.

I have Microsoft Dynamics 365 for Operations in my VM. 

  1. In Visual Studio 2015, I have created a new project and trying to customize an existing report.
  2. I open the report. Go to the dataset and select "Query" as the "Data Source Type" in the properties window. Go to the Query property and click "..." to open the dialog. 
  3. Select any Query and click next, I get the error "Exception occurred on the metadata service on client or server".

2063.MetadataError1.JPG

6787.MetadataError2.JPG

Thanks,

Syed

  • Mats Weigand Profile Picture
    Mats Weigand 2 on at
    Exception occurred on the metadata service on client or server - error
    @ciarand
     
    Had the same issue and the suggested solutions did not resolve it.
     
    After some try and error I figured it out: 
     
    The cloud hosted dev machine was deployed using a generic admin account.
    The admin of the d365 environment was a different admin account.
    My user was none of those admin accounts.
     
    So I changed the account AAD email in "K:\AosService\WebRoot\Web.config" and "K:\AosService\PackagesLocalDirectory\bin\DynamicsDevConfig.config" to the admin account of the d365 environment instead of my user.
    Everything worked fine after that.
  • ciarand Profile Picture
    ciarand 2 on at
    Exception occurred on the metadata service on client or server - error
    I am having the same issue i have tried the actioned mentioned and not have resolved the issue ?
     
    Actions taken so far:
    add ADD email to K:\AosService\WebRoot\Web.config
    add AAD email to K:\AosService\PackagesLocalDirectory\bin\DynamicsDevConfig.config
    also removed the original report in managment report and redeployed ?
     
    Are there any other suggestions as i need to use a query for a report and at present i can access.
     
     
  • makdax2012r3 Profile Picture
    makdax2012r3 50 on at
    RE: Exception occurred on the metadata service on client or server - error

    open your visual studio project in which you have developed report 

    1 open report and right click on report Data Source select edit option from menu an error msg shows you that tells the table relation has missing go to the query table relation and fixed it 

    2 rebuild the report 

    3 add to AOT 

    3 deploy report 

    4 clear your AOT caches  

    and run the report 

  • Suggested answer
    Ismail Tunca Profile Picture
    Ismail Tunca 10 on at
    RE: Exception occurred on the metadata service on client or server - error

    Hi all,

    For me changing K:\AosService\WebRoot\web.config file Provisioning.AdminPrincipalName key value to my e-mail address worked.

    D365FO changes DynamicsDevConfig file OfflineAuthenticationAdminEmail key with this value.

    https://arbistech.com/d365fo-ssrs-report-query-field-listing-error-exception-occurred-on-the-metadata-service-on-client-or-server-error-forbidden/

    Don't forget to restart IIS / IISexpress and Visual Studio after changing value. 

  • Suggested answer
    RM-22040759-0 Profile Picture
    RM-22040759-0 2,014 on at
    RE: Exception occurred on the metadata service on client or server - error

    We had faced the same error in one of our development environments, following below steps to resolve the error.

    1. Verified OfflineAuthenticationAdminEmail id,  as per above suggestions, everything was setup properly.

    2. Closed Visual studio

    3. Started IIS services

    4. Opened Visual studio and verified - Everything working as expected

    Best Regards,

    Ravi Theja Madisetty

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Exception occurred on the metadata service on client or server - error

    Hi,

    Even after done with full build with referenced packages, DB sync, deployed reports to SSRS through powershell,

    changed the AAD user on DynamicsDevConfig.xml file, restarted the environment still the issue persists.

    Any further suggestions would be of great help!.

    In my case this one is a MS hosted environment.

    Thanks

    Ajay

  • veera seenivasan Profile Picture
    veera seenivasan 575 on at
    RE: Exception occurred on the metadata service on client or server - error

    Hi Emincas ,

    I am facing the same problem what settings i have to change in DynamicsDevConfig.xml file?

  • Suggested answer
    Ahmet Coskun Profile Picture
    Ahmet Coskun 16 on at
    RE: Exception occurred on the metadata service on client or server - error

    It's worked. Thanks a lot.

  • Rajesh Bongu Profile Picture
    Rajesh Bongu 45 on at
    RE: Exception occurred on the metadata service on client or server - error

    The solution works fine @emincas.

    Thanks.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Exception occurred on the metadata service on client or server - error

    Thank you !

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 Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

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... 291,711 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,458 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans