Question
MUFG Pension & Market Services
IN
Last activity: 4 Oct 2018 13:54 EDT
Difference between Obj-operations and RDB-operations? Obj-open vs Obj-open-by-handle?
1) Can anyone tell me what is the difference between Obj-operations and RDB-operations?
a)In terms of performance.
b)In terms of functionality
c)In terms of Limitation i.e. when to use what?
2) exact difference between Obj-open vs Obj-open-by-handle?
a)In terms of performance.
b)In terms of functionality
c)In terms of Limitation i.e. when to use what?
Can you explain me with example to understand better?
Thanks in Advance.
***Updated by Moderator: Vidyaranjan. Removed user added #helpme and Ask the Expert tags. Apologies for confusion, shouldn't have been an end-user option***
**Moderation Team has archived post**
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.
-
Likes (3)
Sai Siva Varma Bhupathiraju PANKAJ KUMAR S MANOJ KUMAR REDDY -
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Pegasystems
IN
1) Can anyone tell me what is the difference between Obj-operations and RDB-operations?
a)In terms of performance.
b)In terms of functionality
c)In terms of Limitation i.e. when to use what?
Obj- operations generate their own SQL while RDB- operations rely on the query written in Rule-Connect-SQL instances. Unless there is a need for custom SQL which cannot be solved by Obj- operations, RDB- operations are best avoided. That said, in situations where you need to insert using a select statement or delete multiple records based on a filter criteria, equivalent Obj- operations are currently not available and thus RDB- operations are useful.
2) exact difference between Obj-open vs Obj-open-by-handle?
a)In terms of performance.
1) Can anyone tell me what is the difference between Obj-operations and RDB-operations?
a)In terms of performance.
b)In terms of functionality
c)In terms of Limitation i.e. when to use what?
Obj- operations generate their own SQL while RDB- operations rely on the query written in Rule-Connect-SQL instances. Unless there is a need for custom SQL which cannot be solved by Obj- operations, RDB- operations are best avoided. That said, in situations where you need to insert using a select statement or delete multiple records based on a filter criteria, equivalent Obj- operations are currently not available and thus RDB- operations are useful.
2) exact difference between Obj-open vs Obj-open-by-handle?
a)In terms of performance.
b)In terms of functionality
c)In terms of Limitation i.e. when to use what?
Can you explain me with example to understand better?
Obj-Open opens the instance of a class based on values for all the key properties as defined in the class definition. Obj-Open-By-Handle opens the instance of a class based on just the pzInsKey of the record. If pzInskey is present (which means this is not an external class), being the primary key for the table, this query should perform faster since there would be an index for it.
-
S MANOJ KUMAR REDDY Pushkit Arora
MUFG Pension & Market Services
IN
Thank you Rajiv !!
Pegasystems Inc.
US
From a COE/best practice point of view, RDB-* is generally not recommended. We normally recommend our client to use Report Definition in Pega7 (if you don't need to write an activity, which is against guardrail). RDB-* is normally used when you have to write a complex SQL or store proc, but then try to formulate the requirement and design so that you don't need to write complex SQL/store proc because maintenance will be difficult later.
Obj-Open-By-Handle uses primary key (e.g. pzInsKey) to open an instance. Obj-Open allows you to use more than one WHERE clause but make sure columns are properly indexed before using this as there is a performance impact.
-
S MANOJ KUMAR REDDY
Coforge DPA UK Ltd.
IN
Hi Ajay,
In terms of funcationality both Obj operations and RDB can achive the requirement almost.
But performance wise, it's not recommended to use RDB methosd unless we are using external Database to connect and/or we are writing complex data base queries which are not possible with Obj methods.
Coming to difference between obj-open and Obj-Open-By-Handle:
As in the screenshot attached, both need to be passed parameter(s) to fetch record(s) from the Database. But Obj-Open-By-Handle can accept only a single parameter in general cases we pass pzInskey to fecth a record. Obj-open can accept more than one parameter infact a class which is having values to be passed can be mentioned. So, Obj-Open-By-Handle works on primary key only as there is a single unique row is returned after passing the primary key, but in obj-open we can pass any keys.
Infosys
IN
Do we really pass any keys in Obj-Open ?? did you checked?
-
Lydia Panjaitan Sowmya Bhanuri
Updated: 23 Nov 2016 4:58 EST
Aaseya IT Services
IN
When the pzInsKey is available and when it is not available
Pegasystems
IN
pzInsKey is a computed value by the Pega platform to uniquely identify each record / instance of a class. You might want to read through these documents for more details
https://docs-previous.pega.com/generating-synthetic-customer-data-pega-marketing
https://collaborate.pega.com/comment/105206
-
VIVEKANANDA REDDY MALLEKALUVA
Datacom Pvt LTD
NZ
obj -open is used get value for knowing filtering criterea. ex: ID, Key,
obj open by handle used to only in internel DB. becouse it get exact table row values using Inskey
Coforge DPA
AU
Hi,
pzInsKey is a unique key for every rule in Pega.
Thanks,
Manikumar
Mphasis Corporation
US
Obj-Operations are performed on pega internal DB and no need to provide SQL script while performing these operations. Where as RDB-Operations are mostly used to interact with external DB, need to provide customized SQL script.
Mphasis Corporation
US
Obj-Open accepts any number of parameters where as Obj-Open-by-Handle expects only unique (pzInsKey) defined on class rule form.