Skip to Content
0

Why does my cds view with parameters and odata publishing not work?

Aug 14, 2017 at 07:23 AM

171

avatar image

Dear community,

I have created a simple CDS view.

@AbapCatalog.sqlViewName: 'ZZ_MYVIEW_S'
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #CHECK
@EndUserText.label: 'Summary view'
@OData.publish: true


define view ZZ_MYVIEW
//with parameters p_type: abap.char(1)
as select from ZZ_PARENTVIEW {
    key date,
    key time,
    key state,
    count (*) as cnt
}
//where type = '1'
group by date, time, state;

Now I want to select only a certain type of entries from the parent view (field "type"). The version with "where type = '1'" works, but is somehow not flexible enough. So I wanted to change the code, using a parameter "p_type". When I remove the comment from the line "with parameters", I get the following error:

"OData exposure not supported for view parameters without DDIC data element"

Does anyone has an idea, what this means? And how I can fix this?

(PS: I use Netweaver 7.50)

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Gokhan Yilmazturk Nov 18, 2017 at 02:40 PM
0

Hi, did you find any solutions to this ?

Best Regards,

Gokhan

Share
10 |10000 characters needed characters left characters exceeded