cancel
Showing results for 
Search instead for 
Did you mean: 

json over odata

ushalekha
Participant

How JSON is Useful over oData??

pfefferf
Active Contributor

What exactly you want to reach with your question? That is not really clear with that six words question. If you want to have a good answer I would recommend to invest some more time in asking your question.

kyo_choi2
Participant
0 Kudos

JSON is one of the exchange format that SAP OData uses. It's preferred over XML due to it uses name value pair instead of more complex XML.

View Entire Topic
santoshgowda
Participant

hi ushalekha,

JSON is just a data-interchange format based on JavaScript.

REST is an architecture style whereas OData is a specific implemenation of REST designed to generate and consume data, which supports two formats, AtomPub and JSON.

So the difference between JSON with plain REST and OData are the options in OData for data manipulation eg, if we query data using OData protocol, we can specify the below options in the URI,

  • $orderby
  • $top
  • $skip
  • $filter
  • $format
  • $select

We can do projection, link the resources, etc. and all these options are available out of the box. Now imagine if we had to provide all these features in our own REST service then we would have to,

  • Implement all of them
  • Create our own convention/keywords for different operations

It is not only lot of work but also leads to inconsistencies and creates a learning curve for our data consumers.

Where you can use JSON for testing your application and by using mock server you can use JSON data as service.

Thanks and regards,

Santhosh