cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Using a sum for a colum in a table lookup

paolotaverna
Deputy Chef I
Deputy Chef I
 

Good day, hope all is well, 

 

I am trying to make a sum of a column in a lookup table depending on the id (right now I hard coded the id for testing purpose).

I have tried many formulas but it doe not seem to work.  see my pluck image. 

Please help ๐Ÿ™‚  I would like to avoid looping on the table. 

CleanShot 2025-02-27 at 08.01.22@2x.png

CleanShot 2025-02-27 at 07.55.15@2x.jpgCleanShot 2025-02-27 at 07.58.02@2x.png

5 REPLIES 5

Prudvi
Executive Chef I
Executive Chef I

Hi @paolotaverna,
Can you try using 
Entries[datapill].where('Id':Id[datapill]).pluck('Duration Hours').sum
It will search for Id in the entries and then pluck the column and do the sum
Regards,
Prudvi

paolotaverna
Deputy Chef I
Deputy Chef I

Thank you Prudvi, 

I now get this , Error calculating input for field 'temo_1': no method '+' for nil. 

I have remove the where to simply test without it but get same error. It's driving me nuts ๐Ÿ™‚ 

This is the output of previous task 

  • {
    •   Entry ID: 20285829294,
    •   Entry: {
      •     id: IEAEQSOOKRPXABKY,
      •     title: Faire la demande d'offre de service pour gestion de changement (Formation et accompagnement),
      •     cumul 1: 24782.0,
      •     start: 2025-01-12T09:00:00,
      •     due: 2025-02-08T17:00:00,
      •     parent_folder_id: ["IEAEQSOOI5PW77JN"],
      •     Progress: 100.0,
      •     Duration Hours: 656.0,
      •     taskprogress_x_taskduration: 656.0,
      •     cumul 2: 656.0
        }
    }CleanShot 2025-02-27 at 08.55.54@2x.png

 

 

Hi @paolotaverna,
You can use compact formula to remove if there is any nil in the table.
Regards,
Prudvi

paolotaverna
Deputy Chef I
Deputy Chef I

Again thank you ! I was almost excited!!! 

Error calculating input for field 'temo_1': no implicit conversion of String into Integer

I tried adding .to_f but still not working 

Previous step : Duration Hours: 656.0,