Question

2
Replies
141
Views
bogga Member since 2015 28 posts
PEGA
Posted: 2 years ago
Last activity: 2 years 5 months ago
Closed

How to implement below query in RD

SELECT * FROM pegarules.pr4_rule_vw DRS where DRS.PYRULESET IN ('PegaCSFSM','PegaFSM',) AND DRS.pyRuleAvailable !='withdrawn' AND

(select COUNT(*) from pegarules.pr_index_reference IR INNER JOIN pegarules.pr4_rule_vw DR

ON

(DR.pxInsName=IR.pxReferencingInsName AND DR.pyClass=IR.pxInsIndexedClass AND DR.pyRuleSet=IR.pxReferencingRuleSetName

AND DR.pyRuleSetVersion=IR.pxReferencingRuleSetVersion AND IR.pyRuleName = DRS.pyRuleName AND IR.pxRuleObjClass=DRS.pyclass) where DR.pyRuleAvailable !='Withdrawn') = 0;

We are able to implement inner query

select COUNT(*) from pegarules.pr_index_reference IR INNER JOIN pegarules.pr4_rule_vw DR

ON

(DR.pxInsName=IR.pxReferencingInsName AND DR.pyClass=IR.pxInsIndexedClass AND DR.pyRuleSet=IR.pxReferencingRuleSetName

AND DR.pyRuleSetVersion=IR.pxReferencingRuleSetVersion AND IR.pyRuleName = DRS.pyRuleName AND IR.pxRuleObjClass=DRS.pyclass) where DR.pyRuleAvailable !='Withdrawn' easily in a single RD using inner join and COUNT function but how to implement the complete query

User Interface
Moderation Team has archived post
Share this page LinkedIn