When two users try to edit a business object at the same time, the
modifications made by one user can overwrite the changes made by another. The
same is true for business object connections. To prevent such concurrent
modifications, the kernel provides the ability to mark a business object or
connection as reserved and store its reservation data. The kernel does not in
itself prevent concurrent modifications. Applications using the kernel can use
the reservation data to implement ways to warn or disallow users from modifying
a reserved object.
When an object or connection is reserved, the kernel adds the
"reserved" tag which includes a user and a timestamp. An application can be
programmed such that it checks for the reserved status of a business object or
connection, and if reserved, can issue a warning or disallow other users from
modifying the business object or connection until it is unreserved.
An application can be programmed such that no one can modify a reserved
business object or connection unless it is unreserved. To query the reserved
status of a business object or connection, implementors can use the following
selectables:
Selectable
|
Description
|
Output
|
reserved
|
Boolean indication reserved status of a
business object
|
True/False
|
reservedby
|
Non-empty string or the context user
|
Name of the person who reserved the object
|
reservedstart
|
The data or timestamp of then the business
object was reserved
|
Returns the date and time of when that object
was reserved
|
reservedcomment
|
Optional comment not exceeding 254 characters
from the person reserving the object
|
Any comments entered
|
For example:
print businessobject "Box Design" "Thomas" "A"
select reserved reservedby reservedstart reservedcomment;
|
The above command returns output similar to:
reserved = TRUE
reservedby = Jerry
reservedstart = 30-Oct-2005 10:34:10 AM
reservedcomment = "reserved from Create Part Dialog"
|
To query the reserved status of a connection, use:
print connection 62104.18481.31626.56858 select reserved;
|