- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Need to join case table table with survey response table(asmt_metric_result) but i want to show data of only two metric type .
please help me to define where clause
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
I have used a where clause like this joining the asmt_metric_result table to the asmt_assessment_instance table:
aai_sys_id = amr_instance && aai_metric_type = '4c309f1c3b131300bc1e832b44efc492'
Since you have two sys_ids / metric types, there could be a limitation on the where clause capability, so if the above works for one, something like
aai_sys_id = amr_instance && (aai_metric_type = '4c309f1c3b131300bc1e832b44efc492' || aai_metric_type = '12345678...')
may not work for two. In this case, you can leave both out of the where clause and create a before Query Business Rule, using the Database View as the table to only show the two metric types. Give this a shot and post the script if you get stuck.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
I have used a where clause like this joining the asmt_metric_result table to the asmt_assessment_instance table:
aai_sys_id = amr_instance && aai_metric_type = '4c309f1c3b131300bc1e832b44efc492'
Since you have two sys_ids / metric types, there could be a limitation on the where clause capability, so if the above works for one, something like
aai_sys_id = amr_instance && (aai_metric_type = '4c309f1c3b131300bc1e832b44efc492' || aai_metric_type = '12345678...')
may not work for two. In this case, you can leave both out of the where clause and create a before Query Business Rule, using the Database View as the table to only show the two metric types. Give this a shot and post the script if you get stuck.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi Brad
Thankyou for your response. Luckily
its working fine .I am accepting your response as solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi @priyankar umesh ,
Can't you "just" dot-walk from asmt_metric_result table to the case table instead of creating a database view, or is there some context that i'm missing?
If my answer has helped with your question, please mark my answer as the accepted solution and give a thumbs up.
Best regards
Anders
Rising star 2024
MVP 2025
linkedIn: https://www.linkedin.com/in/andersskovbjerg/
