Sumproduct with two different lists

Not really a solution, but more of a comment: This is a very annoying issue with Bubble that really catches folks off-guard when they run into it.

The main problem is that vanilla Bubble provides very limited capabilities for iteration and Repeating Groups are not actually one of them. The fact that you can do what I would call “display math” in a Repeating Group doesn’t make them useful as iterators, as @agcmateus is discovering.

The fact is, RG’s are a display element and, in a code-based application, we would of course first do our computations and then display them in a repeater.

RG’s cause folks to conflate computation and display. (And while I respect other plugin devs who have attempted to solve this issue the “backward” way – by plucking values out of the dom and sending them to Bubble – that’s just… well… backward.)

In these sorts of situations, what you should do is do the computation and then display it. But Bubble makes this difficult (nigh-impossible in vanilla) due to the lack of a :forEach or :map type expression operator for lists, no built-in way to iterate over a client-side workflow(s), and (sometimes equally vexing) lack of support for custom objects in-the-page.

My free List Shifter plugin provides a couple of workarounds for these problems. It has support for iterating over a list via a workflow (which – let me be clear – is stupid slow for simple things like mathematical operations) via its ITERATE Actions and also via an Action called PROCESS List (which provides a funky, but no-code approach to creating iterative functions that operate more-or-less at native JavaScript speed). See this reply and video link in the main List Shifter thread for simple examples of how to use both of these features:

Unfortunately, PROCESS List is greatly underutilized since Bubble doesn’t let us plugin devs create super-great interfaces and it seems people get overwhelmed with its apparent complexity, but it’s actually really simple to use.

I’m currently working on (and am almost code-complete) on a new commercial plug-in that’s sort a more friendly approach to the sorts of things that List Shifter does (with more robust error checking and other niceties and a whole bunch of unique functionality). It introduces a new (and more flexible) approach to iterating over workflows, as well as an action that lets you simply write a little JavaScript and execute it as a .map(), .forEach(), etc. over some List.

Based on this particular thread (and others like it), I’ll probably add an Action or actions for doing “simple math” on a List and sending it to various plugin outputs. Still, Element plugins are not the ideal interface for stuff like this (but necessary at the moment), and one does wish that we could return values to the workflow for client-side Action plugins (as we can do in server-side action plugins), or access to an Expressions API for extending the expression editor. :man_shrugging: