0% found this document useful (1 vote)
378 views4 pages

Obj Browse

The Obj-Browse method in Pega searches instances of a specified class and copies matching results to a destination page. It takes parameters like the class to search, maximum records, and an optional selection criteria array. The method returns data to a step page or new Code-Pega-List page along with metadata like record count and query time. Selection criteria allow searching on property values and results can be sorted.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (1 vote)
378 views4 pages

Obj Browse

The Obj-Browse method in Pega searches instances of a specified class and copies matching results to a destination page. It takes parameters like the class to search, maximum records, and an optional selection criteria array. The method returns data to a step page or new Code-Pega-List page along with metadata like record count and query time. Selection criteria allow searching on property values and results can be sorted.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

What Is Obj-Browse In Activities In PEGA-

PRPC

Obj-Browse method In Activities


Use the Obj-Browse method to search instances of one class and copy the entire
instances, or specified properties, to the clipboard as an array of embedded pages.

Parameters Obj-Browse method In Activities


The Obj-Browse method has five base parameters and an optional array of selection
criteria.

Types Of Parameters In Obj-Browse method In


Activities

Parameter Description
PageName Enter the name of the destination page to contain search results. The
system uses Code-Pega-List as the class of this page.
Obj Class Identify a class to search. You can search one concrete class, or all
classes in a class group. Within the PegaRULES database, the class can
correspond to a database table or to a database view.
MaxRecords Optional. Enter the maximum number of instances you want returned in
the list at runtime. If left blank, the default value is 10,000.
As a best practice, specify a MaxRecords value to reduce the demand
for database activity memory. If necessary, your activity can test the
property pxMore on the results page to see whether additional rows were
not returned because the MaxRecords limit was reached.
GetRowKey Select to include the primary key in the set of property values returned.
Clear to exclude the primary key. (Selected by default.)
RowKey Optional. Leave blank unless the class in the ObjClassparameter
corresponds to an external table. Enter the name of a property in the
external table, or an expression involving one or more property names,
that specifies the unique key of rows of the external table.
ReadOnly Select to mark the embedded pages for the selected instances as read-
only, meaning that later processing by the requestor cannot update or
delete data in the page. Leave unselected if you plan to update the
embedded pages.
As a best practice, select this checkbox. This records your intent that the
embedded pages are not to be altered and can reduce memory
requirements by retaining only specific property values extracted from
the Storage Stream (Blob) column.
Marking the embedded pages as read-only with this checkbox prevents
changes to the values of properties on the embedded pages. It does not
affect your ability to remove an embedded page completely (with the
Obj-Filter or Page-Remove method).
If the Select array is empty, the ReadOnly setting is ignored. The result
of the method is a Code-Pega-List structure that contains all rows and all
columns of the object, including the Storage
Stream pzPVStream (BLOB) column. The embedded pages are not read-
only.
Logic Optional. Enter a boolean statement that defines how the rows of the
parameter array are to be combined. Identify rows by the Label field.
You can use the operators AND and OR in this statement, and
parentheses for grouping.
For example, A AND (B OR C OR (E AND F)).
If you leave this blank, the system assumes the AND operation applies
to all rows of the array.
Optional. Complete one or more rows of this array to define the
selection criteria and the properties to be returned. If you leave this array
blank, all rows (and all columns including the pzPVStream column) are
selected, up to the MaxRecords limit.
For an external class, complete at least one row of the array.
Label Enter a unique letter or identifier for this row, referenced in
the Logic field.
Select Select to return the value of this property on each embedded page. In the
resulting SQL statement at runtime, this property is listed in the
SELECT list (as well as the WHERE condition).
Field Enter a property reference. You can specify a Single Valueproperty, a
list or group property, or individual elements of a list or group property.
You can return any property — exposed as a column or not — in the
results by setting the Condition field to Value Only. However,
only Single Value properties exposed as database columns can be used
as selection criteria.
Click the pencil button to open the property. (Do not use the magnifying
glass icon )
To restrict the search to specific values of a property, enter a property
reference that is exposed as a database column. You can review the
database schema to determine which properties are exposed for a class.
Consult your database administrator for information on the current
database schema, or use the Modify Schema facility. See How to expose
a property as a database column.
Condition Select a comparison, such as Is Equal or Is Less Than.
 Select Value Only if the search results are to include the property
value, but the property value is not to be used as a selection
criterion.
 Select Is Null to require that the field a have null value.
 Select Is Not Null to require that the field have a value.
If the property is not exposed as a database column, selectValue Only.
Value Enter a constant value, a property reference or other expression for the
comparison. Leave blank if theCondition is Value Only, Is Null, Is Not
Null, Is True or Is False.
Click the pencil button to open a property. Click the magnifying glass
button to start the Expression Builder.
 If you enter an expression involving function rules, Java, and
properties on various clipboard pages, then at runtime the
expression is evaluated only once.
 If you enter a property (that is exposed as a column) that applies to
the ObjClass class, the Value value is evaluated for each row.
For example, if the Field field contains a DateTime property
ExpireDateTime, the Condition is IS GREATER THAN, and theValue field
contains a function computing the current date and time, the function is
evaluated only once, not once per row.
But if the Value field contains a second property RenewalDateTime,
then the system compares the value of the two properties
ExpireDateTime and RenewalDateTime for each instance of the class.
Sort Select No Sorting, Ascending, or Descending to control the sorting of
results by this field. (Sorting occurs through database software, on the
database server.)
If the Condition is Value Only or Is Null, select No Sorting.

The Obj-Browse method returns the data either to a previously created step page —
which is cleared and reused — or to a new page of that this method creates of
class Code-Pega-List. The system writes search results in the specified step page,
along with information that controlled the search.
This method also adds or updates these properties in the step page:
 pxResultCount — A count of the instances retrieved by this search.
 pxMore — Indicates whether there are more instances in the database that were
not returned. Values are true or false.
 pxNextKey — Indicates the key of the first row (instance) not returned,
ifpxMore is true.
 pxElapsedTime — Seconds of elapsed time spent executing the request.

You might also like