Repeat Server Action Conditions And Sort

Just wondering what is the most effective way to run this server action, in short the main query repeat_rows pulls a list of content in a db lets say it pulls 100 records for this page.

Now when the newt part runs the repeat loop all the queries would run 100x but in these queries the rows left query for example may only need to run 20 times but as its in the repeat loop of repeat_rows it runs 100 etc

would the best route be a condition tree or can we apply a condition to the repeat loops directly (if I select a returned individual value from the repeat_rows I can’t select outputs) or is there a totally better way to go about this

Community Page
Last updated: