21.03.2013 Views

Object Oriented ABAP

Object Oriented ABAP

Object Oriented ABAP

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Persistent <strong>Object</strong>s: Using GUID <strong>Object</strong> Identity<br />

<strong>Object</strong>ive<br />

To Store the attributes of the <strong>Object</strong>s persistently in the database.<br />

Persistent <strong>Object</strong>’s Identity<br />

Every Persistent <strong>Object</strong> has a unique identity with which it can be accessed. There are 2<br />

types of <strong>Object</strong> identity<br />

1. Business Key<br />

2. GUID( Global Unique Identifier )<br />

For Persistent <strong>Object</strong>s using Business key Identity please check my previous article,<br />

“Persistent <strong>Object</strong>s: Using Business Key identity”<br />

This article will focus only on Persistent <strong>Object</strong> using GUID.<br />

Step: 1 -> Create a database table<br />

This table should contain a key field of type OS_GUID.<br />

Step: 2 ->Create a Persistent Class<br />

Go to Class Builder (tcode SE24)<br />

Give persistent class name for eg ZCL_PERSIST_02 and hit the create button

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!