Posts
Showing posts from May, 2012
Creating View Criteria having Exists clause at run time
- Get link
- Other Apps
This post is in continuation of one of my old post Creating View Criteria having Bind Variables at run time. In this post I'm sharing sample for creating view criteria with Exists clause at run time. The following code snippet illustrates the API usage for creating View Criteria with Exists clause.
public void buildVCWithExistsProgrammatically(String departmentName, String email) { //Following code snippet defines view criteria on DepartmentsView //This view criteria contains 2 ViewCriteriaItem //1. A normal ViewCriteriaItem for DepartmentName attribute //2. The second ViewCriteriaItem is based on Exists clause DepartmentsViewImpl voDept = getDepartmentsView1(); voDept.clearWhereState(); VariableValueManager vvm = voDept.ensureVariableManager(); ViewCriteria vcDept = voDept.createViewCriteria(); vcDept.setName("TempVC"); ViewCriteriaRow vcrDept = vcDept.createViewCriteriaRow(); …
public void buildVCWithExistsProgrammatically(String departmentName, String email) { //Following code snippet defines view criteria on DepartmentsView //This view criteria contains 2 ViewCriteriaItem //1. A normal ViewCriteriaItem for DepartmentName attribute //2. The second ViewCriteriaItem is based on Exists clause DepartmentsViewImpl voDept = getDepartmentsView1(); voDept.clearWhereState(); VariableValueManager vvm = voDept.ensureVariableManager(); ViewCriteria vcDept = voDept.createViewCriteria(); vcDept.setName("TempVC"); ViewCriteriaRow vcrDept = vcDept.createViewCriteriaRow(); …
Disclaimer
The views expressed on this blog are my own and do not necessarily reflect the views of my employer.