on 2020 Jun 20 6:34 PM
Hello,
i have an analytic query and when i try something like "$select=Customer" in SAP Gateway Client it gives me a grouped result and everything is fine. But when i try it with my Service in the WEbIDE and have "$select=ClusterName" in my query options for a list there are no values visible 😞
Maybe someone can help me 🙂
Kind Reagrds
Fabian
Help others by sharing your knowledge.
AnswerRequest clarification before answering.
Can you try setting the checkResults property in you .service configuration file to false and see if that helps.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Fabian,
As a workaround, in your MDK .service metadata, please set the Service Option for fixMissingNullValues to true.
"OnlineOptions": {
"ServiceOptions": {
"fixMissingNullValues": true
}
}
This should allow the query to return the result set expected. We are still looking into this further as well from our side.
--Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Fabian,
$select is used to return a subset of fields from the backend. If you are using a v4 service then you can look at using groupby and aggregate. These are not supported in Odata v2.
Another option would be to define an aggregate entity that does the aggregation in the backend and returns that aggregated data. This would work with either v2 or v4 but may require modifying your odata service to add the new entity set and associated backend logic.
--Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey Bill,
thanks for anwering. I requested our Basis team to activate OdataV4. I hope that i am somehow able to "convert" myOdata-Service into a V4-Service.
But the thing i dont get when using $select is that is is doing the right things when i call it frm the SAP Gateway. It seems that it is getting the correct data (See screenshot). But i dont really get why this is not visible in my app. Maybe you could help here again? 🙂
screenshot-select.jpg
Kind Regards
Fabian
Please keep in mind that currently if you want to create an offline MDK application we only support OData v2 services.
Your screenshot appears to show that it is correctly only returning the one column. Can you share the metadata for your list page that you say is not showing anything? Could it be that you are attempting to bind to a property that doesn't exist in the result set when you use the $select?
--Bill
Thanks Bill. Anish answer solved my issue 🙂
Btw. i am only able to work with online data because i have an error when i try to use an analytic query for offline data. It means something like ID is too long or has values which are not allowed. I guess that the issue is here that my ID is to long. See my screenshot, there is they ID around 80 digits long 😄 You have a good hint here? 🙂
Kind Regards
Fabian
Fabian,
We have reproduced this internally and are looking into it further.
--Bill
User | Count |
---|---|
73 | |
18 | |
9 | |
8 | |
7 | |
4 | |
4 | |
4 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.