odata

一个CRM OData的性能问题分析

China☆狼群 提交于 2020-02-08 19:41:09
In My appointment application, when jerry clicks F4 on account field, there will be odata request to retrieve account information. To my surprise, this odata request took more than one minute to get response: Then I did a performance trace in jerry system and found out most time is spent on your code CL_CRM_BP_ODATA_RT~ SELECT_ENTITYSET_BY_SQL. [外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-ANZPgsKn-1580818103722)( https://upload-images.jianshu.io/upload_images/2085791-389aca4950fcc13e.png?imageMogr2/auto-orient/strip )] I wrote a report in jerry system MOR/300 to reproduce this performance issue,

OData call with $filter and $expand simultaneously

Deadly 提交于 2020-01-25 18:03:43
问题 I've been trying to call a entity, but i'm supposed to call the results from its associated entities. I tried to do it with the following URL: /sap/opu/odata/XXXXXXXX/SERVICE_NAME/MatnrGetdetailCollection?$filter=IVendorId eq '1701' and ILanguage eq 'P' and IMaterial eq 'M-05'&$expand=MatnrClassGetdetail I must use the filter because the called function has these mandatory parameters. Am I making any mistake on the URL or the error isn't there? 回答1: In general $filter and $expand can be

OData call with $filter and $expand simultaneously

…衆ロ難τιáo~ 提交于 2020-01-25 18:02:57
问题 I've been trying to call a entity, but i'm supposed to call the results from its associated entities. I tried to do it with the following URL: /sap/opu/odata/XXXXXXXX/SERVICE_NAME/MatnrGetdetailCollection?$filter=IVendorId eq '1701' and ILanguage eq 'P' and IMaterial eq 'M-05'&$expand=MatnrClassGetdetail I must use the filter because the called function has these mandatory parameters. Am I making any mistake on the URL or the error isn't there? 回答1: In general $filter and $expand can be

WCF DataService indent xml response

别来无恙 提交于 2020-01-25 10:35:25
问题 How can i indent the xml response from my data service? All my request to the wcf data service are in xml wihout indent. I am using OData3 WCF Data Service 5.0 . Before in Odata WCF Dataservice 4, all my response data was in indent xml. 回答1: It seems that since wcf dataservice 4.0 was update in WCF Data Services 5.0 with OData 3.0, all the xml response is not intent, i solved this by implement the IDispatchMessageInspector interface and modify the current content by xdocument and

OData v4 order by multiple cardinality property

久未见 提交于 2020-01-25 04:38:05
问题 I have the following url: {{hostUrl}}/odata/TasksOData?$select=Id,Name,State,TaskRuns,LastChangedAt,LastChangedBy&$expand=TaskRuns($orderby=RunAt desc;$top=1;$select=Status,RunAt,RunBy)&$top=16&$orderby=TaskRuns/RunBy I want to order Tasks by property from TaskRuns(RunBy). TaskRuns being a collection I want to take into consideration only first item. I get error: "message": "The parent value for a property access of a property 'RunBy' is not a single value. Property access can only be applied

How to apply paging specifically to a list which is part of a JSON using asp.net OData protocol

风格不统一 提交于 2020-01-25 01:21:09
问题 Below is a get method in my controller. It returns a JSON containing boolean "success', string "message" and a list. How can i query the list using OData? Generally if the return type was IQueryable then the following would work api/Category/all?$top=5 to get the top 5....But what should i do in my case? // Get all Categories [HttpGet] [ActionName("all")] [Queryable] public HttpResponseMessage GetCategoryList() { var categoryList = this.Repository.GetCategories().AsQueryable<Category>();

Microsoft graph: get only users from group

好久不见. 提交于 2020-01-24 12:04:19
问题 Just wondering if there's any way to get only the users placed inside an azure ad group. I've tried something like this: var membros = await obtemUtilizadores .Filter("'odata.type' eq '#microsoft.graph.user'") .Select("id,userprincipalname,mail,displayname") .Expand("extensions($filter=id eq 'assistenciasExtensions')") .GetAsync().ConfigureAwait(false); It translates into this url: https://graph.microsoft.com/v1.0/groups/xxxxxx/members? $filter='odatatype eq 'microsoft.graph.user'& $select=id

Is OData suitable for multi-tenant LOB application?

ぐ巨炮叔叔 提交于 2020-01-24 10:26:27
问题 I'm working on a cloud-based line of business application. Users can upload documents and other types of object to the application. Users upload quite a number of documents and together there are several million docs stored. I use SQL Server. Today I have a somewhat-restful-API which allow users to pass in a DocumentSearchQuery entity where they supply keyword together with request sort order and paging info. They get a DocumentSearchResult back which is essentially a sorted collection of

OData substringof or startswith returning all items

為{幸葍}努か 提交于 2020-01-24 02:41:08
问题 I'm trying to filter my results from a Rest Call. $.ajax({ type: "GET", headers: { "Accept": "application/json;odata=verbose" }, dataType: "JSON", url: _spPageContextInfo.webServerRelativeUrl + "/_api/lists/getByTitle('Contacts')/items?$select=Title,Id&$startswith('Title','" + request.term + "') eq true", success: function (data) { }, error: function (ex) { } }); In my Contacts List i'm trying to retrieve the Title and the Id for Items which start with a String or which have the String

WebApi OData v4 ComlexType cannot have an EntityType

徘徊边缘 提交于 2020-01-23 11:22:08
问题 We were using WebApi OData v 3 and had a couple ComplexType entities defined in the entity data model that contained EntitySet entities. When moving to OData v 4 and upon doing the modelBulder.GetEdmModel() step we get an InvalidOperationException "The complex type 'Foo' refers to the entity 'Bar' through the property 'Bar'." I look at the spec and see a thing called an "abstract entity type" that is a type that holds entity types. I don't see that in the WebApi OData code so I hope that all