Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

oabap: inheritance in persistent classes

Former Member
0 Likes
369

hi sap gurus,

i want to use persistent classes and require to use in inheritance in them . can any one tell me how to do that

thanks in advance.

1 ACCEPTED SOLUTION
Read only

GrahamRobbo
SAP Mentor
SAP Mentor
0 Likes
334

The class actor generated by the persistent objects wizard (CA_persistent) inherits from the abstract CB_persistent class.

This means you cannot inherit from another class into the persistent class because ABAP does not support multiple inheritance.

Cheers

Graham Robbo

2 REPLIES 2
Read only

GrahamRobbo
SAP Mentor
SAP Mentor
0 Likes
335

The class actor generated by the persistent objects wizard (CA_persistent) inherits from the abstract CB_persistent class.

This means you cannot inherit from another class into the persistent class because ABAP does not support multiple inheritance.

Cheers

Graham Robbo

Read only

0 Likes
334

thank you for reply.

but i have used inheritance when defining the persistent class.

now when i try to call method create persistent of CA class it only creates the instance of subclass not the base class

any idea?