If you open this URL in browser, it shows up the different entity sets.
As you can see in the above image, the entitysets in this OData service are Products, Productdetails, Categories, Suppliers, Persons, PersonDetails, Advertisements. So it includes totally seven entitysets. The entityset ‘Category’ includes information about all categories.
URL is case sensitive. So the first letter ‘P’ in Products must be written in Capital. Otherwise it does not work.
It is much similar to the Transaction SE11 (ABAP Dictionary) where we give the Table name. The Data contents can be displayed for this table.
The URLs mentioned above executes the HTTP-Get methods, which in turn calls the Read-OData method. In the background, the data would be retrieved and the result is sent back.
Let us look into an example of retrieving data records with single primary key.
Specific line of record can also be retrieved by specifying the primary key value in the URL.
In the above case, both the primary key fields are of datatype string. So the value is mentioned in quotes. If the datatype is integer, then quotes should not be used.
Retrieving data records with WHERE clause.
All the products with a particular category ID can also be retrieved. To achieve this, it must be predefined in the services. We can also navigate from one entity set to another. For example, in the below URL, only the data from the product entity set are displayed.