Questions tagged [odata]

The Open Data Protocol (OData) is a standardized protocol for building REST APIs. OData v4 specifies many best practices for REST APIs including a terse, hypermedia-oriented JSON format.

0
votes
0answers
15 views

select - keyword not working with odata, automapper and efcore

I am trying to apply the odata query to my automapper - mappings at my efcore context. Everything works as expected until I use the $select query option. When I try to use the select keyword in the ...
0
votes
0answers
19 views

OData function with ViewModel and Expand

I am trying to create the odata function in c# ODataController, which would return custom model. this is a simple part and it's working fine. Now I want to allow $expand for related entity as well, ...
1
vote
1answer
46 views

Projecting an IEnumerable inside an Projected IQueryable making N Requests to the Database

I'm making an Asp.net Core Api and one of the Actions of the Controller i need to return an IQueryable of a DTO, but one of the properties is an IEnumerable of another DTO in a relationship one to ...
0
votes
0answers
25 views

How to build a Node.js OData service without database

I'm rookie to OData. Now I'm trying to build an OData service with Node.js. All the documents I found are building a Node.js OData service based on some DB, like MongoDB. But that doesn't fit my case, ...
1
vote
0answers
31 views

Pagination with AspNetCore.OData - missing @odata properties in response

I'm trying to implement pagination with asp.net core 2.2 and Microsoft.AspNetCore.OData 7.1.0 with following configuration: public class Startup { public void ConfigureServices(...
0
votes
0answers
22 views

Geographical distance calculation in OData with ASP.net Web API

I want to basically calculate the geographical distance between two points and show only those records whose location is within a certain radius. I have records with geographical values like "...
0
votes
0answers
9 views

Odata query with groupby and rollup

I am trying to figure out the syntax for an Odata groupby with rollup query. I've read (and think I understand) the published oasis documentation but I still get errors. Using a demo Odata service ...
0
votes
0answers
6 views

Is it possible to declare same OData NavigationProperty metadata relationship to more than one entity?

I have an entity, Member, that relates to two other entities, PropertyAgent and TeamMember. I'd like to use the same property, MemberKey, to relate them with but then the XML metadata document ends up ...
0
votes
0answers
15 views

Will Odata version 2.0 be completely decommissioned?

My group inherited an MVC.NET application using Odata version 2.0. We were warned that at some point in the future Odata 2.0 will be decommissioned and we will need to make a decent number of changes ...
0
votes
1answer
19 views

oData service sequence of calls

How to make sequential async requests in chunks of 50 records to a oData service. (function () { // Multiple api calls var oData ="http://localhost:8888/Clinics"; fetch(oData) ....
0
votes
0answers
12 views

Can I use the distinct method like SQL in OData v3?

I would like to query an OData endpoint in order to get a list of distinct values. Is it possible?
0
votes
0answers
11 views

How do I use Custom Query Options with angular-odata-es5

I am trying use the angular-odata-es5 npm-package to access my api with a Custom Query Option, but I don't know how to put it into the configuration. Is this even possible with that library?
0
votes
0answers
9 views

Unknown Error -2146232832, Microsoft.SharePoint.SPException when $filter=OData__ModerationStatus eq 'Pending'

I am facing a weird problem. I have a SharePoint list on where I am trying to query some data using OData REST protocol. In the filter portion, for some columns, sharepoint is sending back the data ...
1
vote
0answers
33 views

Alternate keys oData url is not working with Microsoft.AspNet.oData 7.1.0

I am trying to add Alternate keys for my Edmmodel and later able to query it using oData url. I tried configuring the RouteBuilder in Startup file and added alternate ksys in Model Builder. But ...
2
votes
0answers
41 views

OData Function Encountered invalid type cast. Type is not assignable from '<null>'

Context What's the proper syntax for RetrieveAttributeChangeHistory parameters? Trying RetrieveAttributeChangeHistory from the Dynamics 365 audit entity. I need some help forming the proper syntax ...
1
vote
1answer
25 views

Dynamics 365 RetrieveAttributeChangeHistory OData function for audit entity

Context Trying RetrieveAttributeChangeHistory from the Dynamics 365 audit entity. I need some help forming the proper syntax for the OData function on this entity. Since the function is unbound I am ...
0
votes
1answer
13 views

dynamically adding an array to a resource in run time

I have a custom ODataResourceSerializer which under some conditions adds new properties to a resource, that works perfectly. I am trying to add a new simple int[] property the resource is a dynamic ...
1
vote
2answers
51 views
+50

C# “Resource not found for the segment” error in Odata v3 with status code 200

I am trying to get data from project Online api Url through Odata V3. The problem is that if the resource is not found I get a status code 200 and the request passes the validation and my program ...
0
votes
0answers
34 views

Inconsistent serialization results of DateTime when using API

We save records with a datetime column in a SQL Server database. We get different results when using the OData API, depending on the usage. Suppose there is a record with Id 23415 and a ...
1
vote
0answers
26 views

Can't apply $select when using ODataQueryOptions

I am trying to implement querying to Sql Server via EF Core and OData(7.1.0). Action method looks like follows: [HttpGet] public IEnumerable<UserInfoDto> Get(ODataQueryOptions ops) { ...
0
votes
0answers
12 views

Reading Entity Type Definitions from an IEdmModel

I am trying to dynamically determine entity properties from OData by parsing the $metadata. I have so far been able to construct an IEdmModel and from there I can get the SchemaElements that have ...
0
votes
1answer
36 views

What is wrong with my HttpURLConnection request?

I am trying to call a REST API with a PUT Request but I am receiving a 400 Error Code (Bad Request). Can someone spot what I may be doing wrong? I have successfully called this API with a REST ...
2
votes
1answer
37 views

SSIS OData source works in Visual Studio 2017 but fails when run in Azure Data Factory

When I test the OData source connection in my host with Visual Studio 2017, the connection is ok. However, when I push the SSIS package into the Azure Data Factory and I run it, it fails. The only ...
0
votes
0answers
8 views

Insert DateTimeOffset to subform

I'm trying to insert (POST) new row into sub-form with DateTimeOffset column type "TIMESTAMP@odata.type": "#DateTimeOffset", I'm trying for example to pass this JSON { "TIME_STAMP":"2019-04-...
0
votes
0answers
11 views

Custom routing on controller with oData is not working

I am trying to integrate oData in my application in .net core2.2. I am able to get $metadata response. I need to customize the endpoint of my controller but when I am using [ODataRoutePrefix] or [...
1
vote
1answer
69 views

How to bind oData model to table in block view of object page layout?

How do i bind the model data from the oData entityset response to the table inside the xml block view? I want to set/bind the model data to table rows in the view 'directly' instead of binding it to ...
0
votes
0answers
11 views

Is there a way to include multiple complex filtering conditions in an odata query

I need to filter a list of json objects using multiple nested conditions in Odata. Need to filter all users from a list with task_type as 'XYZ_TASK_TYPE' and event id 'abc_event_id' using odata query....
0
votes
0answers
8 views

How to expose odata V2 java service for data filled POJOs

I am new to OData V2 (java). Below is the scenario or concern I am facing in my application and will like to know about the best way. Intention is to consume an OData service (say service-B), apply ...
0
votes
0answers
21 views

SSIS - OData Connection to Sharepoint List Failed Validation Error

In SSIS (version 15, created through Visual Studio 2017), I am trying to connect to a Sharepoint list ("Deficiencies") with an HTTPS URL. I get this error: Error: 0xC020801F at Deficiencies, Get ...
0
votes
1answer
13 views

return updated object in xsodata update operation exit

I was wondering if it was possible in SAP HANA to update an entity with an xsjslib file and return the updated object. Currently, when updating an entry, it returns '204 - No Content'. Sample of ...
0
votes
0answers
47 views

Dynamics 365 OData filter data from a ComplexType

My goal is to create an OData query that just get the "Value": 100000000, data for the last entry in the Options array. I am required to just send the Value field for the last Option in my response ...
0
votes
0answers
33 views

Odata The method 'GroupBy' is not supported

Using the devextreme below code to get the sum of amount however as I am using Odata, it throws exception of "The method 'GroupBy' is not supported". Yet there is no answer for this mystery. Is there ...
-2
votes
0answers
26 views

OData Metadata doesn't return entityset metadata

When i query my odata metadata, it doesn't return the complete metadata. I need the entity property to be returned as well This is what i entered in browser: https://mysapserver.com/sap/opu/odata/sap/...
1
vote
1answer
44 views

Performing OData methods with Edm.DateTime as part of primary keys

I have the problem, that I want to update a table via HTTP-request. But I always get an error-message on the Edm.DateTime attributes in the table. Error: Invalid URI-Segment '00:00',ValdTo=datetime'...
0
votes
0answers
26 views

How can I create dynamic builder Odata with .Net Core 2.2?

I use Odata with .NET Core. and My Startup.cs file like above public void ConfigureServices(IServiceCollection services) { ...... services.AddOData(); services.AddODataQueryFilter(); ...
0
votes
0answers
37 views

Unable to execute groupby query using OData V4 query syntax in Web API

I am trying to upgrade my web api to use OData V4 query syntax. After upgrading the dlls am able to issue $filter and $select queries for my web api. But When I issue a request like https://localhost:...
3
votes
1answer
49 views

SSIS 2017 OData source - Sharepoint 2016 $expand

Unable to select expanded properties of an expanded type, when using a query with $expand operator. Sharepoint 2016 list contains a 'Person or Group' field (column=Client), when querying the list: ...
0
votes
0answers
13 views

How can I handle and record exceptions thrown in an EntityFrameworkDataService application

This is my first S.O. post, so please pardon any breach of etiquette, and thank you all for the help. I'm working with a RESTful WCF EntityFrameworkDataService, implementing the ...
0
votes
0answers
9 views

Change the processing mode to “routing-based” before adding system alias

While adding OData service from /IWFND/MAINT_SERVICE I get this error Change the processing mode to "routing-based" before adding system alias I am trying to add a service locally pointing to the ...
0
votes
0answers
6 views

How to convert from convert type 'Microsoft.EntityFrameworkCore.Metadata.IModel' to 'Microsoft.OData.Edm.IEdmModel'?

Need to convert type 'Microsoft.EntityFrameworkCore.Metadata.IModel' to 'Microsoft.OData.Edm.IEdmModel' so that I do not have to duplicate code just to use OData v4 with Entity Framework Core context;
3
votes
1answer
42 views

Prevent URL encoding at QueryString.Add()

I am making a Restful api using OData, and for some reasons I want to force the expand filtering inside the middleware. So if the clients sends in http://localhost:52973/odata/customers The ...
0
votes
0answers
9 views

OData API based on 'dynamically' created context from an existing database

I want to create a new OData v4 API within my .net core project for a database of a legacy program. This API should use an EF Core dbcontext. The difficulty is that even though i could create a ...
0
votes
1answer
35 views

“Resource not found for the segment *publisherguid*” in XMLHTTP query to create solution in the CRM

I'm trying to create a solution in the CRM with javascript. My code is a webresource that I get through a Ribbon I created with "Ribbon Workbench 2016". These things work very good, but when I try to ...
2
votes
0answers
43 views

Unable to parse XML data into Java object using XPath

I'm making a call to OData service (similar to REST API call) using my Java program and I'm getting response as well in the XML format. In response, I get an XML where I need to read specific XML ...
1
vote
0answers
19 views

Parse ODATA URL to read ID value before preparing entityset

I'm new to ODATA. The examples given in https://olingo.apache.org builds the entityset first and then out of it, it fetches one entity based on the ID passed in the URL. What i need is how to read the ...
2
votes
1answer
37 views

OData v4.0 - Change value to results

I am currently writing an API but this time, the client-side is 3rd party. Luckily it's well documented, but I have 1 particular issue. The client expect the json like this: { "results":[ ...
0
votes
1answer
28 views

SAPUI5 OData V2 Batch Operations with multiple differed groups

I'm trying to do a batch operation with multiple groupids in a single batch request. and need to get results in two different batch responses. But when I initiate the request only one group has been ...
1
vote
0answers
21 views

How to execute two dependent odata url's in same session from C# Code

I need to call two odata URL's of sap from C# Code. The first URL will set the Filters and the second URL (generic URL) will give the actual response. First URL: https://<>/sap/opu/odata/SALM/...
0
votes
0answers
23 views

OData filter on array property to return empty array or array

I have a JSON object similar to this one: { "customers": [ { "id": 1, "name": "bob", "orders": [{"id": 1, "customerId": 1, "itemId": 6}] }, { "id": 2, "...
1
vote
0answers
17 views

Odata request, query from SQL database, filter on field with JSON string format

I'm running HTTP request against application which is querying SQL database (assumption), and I want to filter on a field which stores JSON format string. I want to filter on properties within the ...

http://mssss.yulina-kosm.ru