Skip to Content
Technical Articles
Author's profile photo Sami Lechner

How to visualize the OData model

UPDATE:

The blog below has become obsolete with the new “mobile backend Generator”. This is a plugin available for the SAP Web IDE which allows modelling an OData service. Existing Metadata documents can also be imported and visualised. For more information read: 

https://blogs.sap.com/2018/09/28/how-to-build-your-mobile-odata-service-from-scratch/comment-page-1/#comment-450868

 

I was recently in the situation that I have a complex OData model I needed to discuss with customers. Going through the metadata document requires a lot of brain power. The previous solution from XOData does not seem to work anymore.

So, I found a brilliant blog from Denise. I modified some steps and with the following steps you can view any Metadata document inside the SAP Web IDE.

  1. open your web IDE in the SAP Cloud Platform Cockpit
  2. create a new Project from Template 
  3. Use the List Report Application and click on Next
  4. Add a project Name and Title and click Next
  5. Click on Filesystem and add your metadata.xml and click Next
  6. Click Next on the Annotation Selection
  7. Select a OData Collection for the List
  8. Click on Finish
  9. now open your project and navigate to Webapp->localService folder and double click on the metadata.xml
  10. switch the view in the bottom left corner from Source to Design 
  11. The Result should be your OData model :

Assigned Tags

      6 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Smriti Gupta
      Smriti Gupta

      Excellent Sami. Can't wait to try it out.

       

      Thanks for sharing it

       

      Best Regards

      Smriti

      Author's profile photo Sanket Chimalwar
      Sanket Chimalwar

      Nice 🙂

      Author's profile photo Daniel Emmenegger
      Daniel Emmenegger

      Hi Sami

      What are the prerequisites for this visualization? I've some projects, where the button isn't available and some, where it works as described...

      Is it also possible to visualize it directly from the Gateway and not from a (maybe outdated) file?

       

      Regards,

      Daniel

       

      Author's profile photo Sami Lechner
      Sami Lechner
      Blog Post Author

      Hi

      I found no limitations on this until now. I am able to upload any metadata file. Yes you can also point this against a live Gateway system if you have added this as a destination in the SAP Cloud platform.

      Author's profile photo Ansgar Erlenkoetter
      Ansgar Erlenkoetter

      Hi, this appears as another great use of our WebIDE.

      I'm trying to browse a metadata file of about 200k and always get "Model is too big to be displayed".

      This metadata file was actually extracted from one of our own APIs.

      Anyone who encountered similar effects and found a cure?

       

      Cheers

      Ansgar

      Author's profile photo Sami Lechner
      Sami Lechner
      Blog Post Author

      see the update in the blog for details