I'm display data from survey_result table on the request screen in a seperate tab, I'm able to fetch the data from survey_result and display it successfully on the request screen using UI Designer,
But the issue is iam getting all the data from survey_result for that Request ID.
where as i want to display only some rows from that survey_result table based on survey_id How can we add a filter condition on UI Designer by which we can get survey_result data for a specific survey_id on the UI Designer
I've tried searching for solutions online, but I haven't been able to find anything that works for my specific scenario.
If anyone has experience with filtering data in a mobile survey based on survey ID, I'd be so grateful for any advice or guidance you can provide.
Thank you in advance for your help! I appreciate your time and expertise.
Best answer by Rwjgoedhart
Yajjala,
I am going to assume that we’re dealing with a 2-part list-view here, 1 to list the Surveys, the other to list the results.
If that is the case:
give your Parent list a name
then set your child list up with Name & Parent
In my example my parent = “TaskList” and my child is “RCAList”
Edit the ListView configuration of the Parent to include child information
In my example I identify the child (on the parent list configuration) and entered the table_name (survey_answer in your case) in both “Child table Name” and “Path”
make sure your “Child Relations” settings match your desired setup.
In your case you would need a link from request to survey (possibly through a view) then link in survey_answer from survey
“survey” would be the parent
“survey_answer” would be the child
Save Screen - Refresh Cache -- Re-open screen - Et Voila! (assuming I didn’t forget something!)
If you were simply looking to add a filter, use “Child relation Editor” to add a constraint to the survey_answer relation, such as this:
Lastly; for a more dynamic single-survey result view, you could also build a custom-view and bring that in instead of survey_result_view
I am going to assume that we’re dealing with a 2-part list-view here, 1 to list the Surveys, the other to list the results.
If that is the case:
give your Parent list a name
then set your child list up with Name & Parent
In my example my parent = “TaskList” and my child is “RCAList”
Edit the ListView configuration of the Parent to include child information
In my example I identify the child (on the parent list configuration) and entered the table_name (survey_answer in your case) in both “Child table Name” and “Path”
make sure your “Child Relations” settings match your desired setup.
In your case you would need a link from request to survey (possibly through a view) then link in survey_answer from survey
“survey” would be the parent
“survey_answer” would be the child
Save Screen - Refresh Cache -- Re-open screen - Et Voila! (assuming I didn’t forget something!)
If you were simply looking to add a filter, use “Child relation Editor” to add a constraint to the survey_answer relation, such as this:
Lastly; for a more dynamic single-survey result view, you could also build a custom-view and bring that in instead of survey_result_view
We use 3 different kinds of cookies. You can choose which cookies you want to accept. We need basic cookies to make this site work, therefore these are the minimum you can select. Learn more about our cookies.