Skip to Content

Facing errors while creating a odata service consuming a calculation view.

HI All.

I am pretty new to XS , I am trying to create an ODATA service from a calculation view . But whenever I try to activate the service I get the following error

"Missing specification of keys for view "demo::CV_PASS1".

Thanks,

Tanush

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    Posted on Apr 04, 2016 at 07:33 PM

    An OData service must have a key specification as a unique URL for each record must be generated. For table sources XSODATA uses the key specification of the table itself as the source of the OData key. Calculation views, on the other hand, have no key structure. You must either specify the key columns within the XSODATA document itself

    service {

    "sap.hana.democontent.epmNext.data::MD.BuyerView"

    as "Buyer"

    keys("Id");

    }

    Or use the KEYS GENERATE LOCAL option to have the framework generate a key for you (useful when you have aggregation):

    service namespace "sap.hana.democontent.epmNext" {

    "sap.hana.democontent.epmNext.models::SALESORDER_DYNAMIC_JOIN"

    as "SalesByCountry" with ("COUNTRY", "TOTAL_SALES", "SALES", "SHARE_SALES")

    keys generate local "ID"

    aggregates always;

    }

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Thomas/Rich,

      Request you to please go through mentioned below Open issued & guide me what to do.

      OData is Straight Less connection hence Unable to keep Controlling the Lock Object / Enqueue Dequeue.

      PI help me out if one have any idea, please share me as it's creating big problem while doing work flow related Approval.

      Thanks for your Time and consideration.

      Thanks in advance.

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.