### List.Range & List.Sum M Formulas

Posted:

**Sun Jun 16, 2019 3:12 am**Hi all,

If someone is familiar with the correct way to use these two formulas as I'm having some difficult. I used the following formula (successfully!) to create a running total calculated column (of time stored as a decimal number):

=List.Sum(List.Range(#Added Index"[TimePerCase],0,[Index]))

However, replicating the conditions & the formula to another situation has made the formula come back with Error. I've checked this isn't to do with the data type I am referring to in each case.

The error message reads that [TimePerCase] is not a 'list' data type. However, the values in both situations are effectively the same. The [TimePerCase] are small decimals around 0.00001. The other workbook interpreted these values as a 'list'.

Does anyone know what might be causing my error? Thanks

EDIT: Does 'List' have a maximum number of records? My current PQ is around 16k rows.

EDIT: Another idea... I believe lists need to start with the lowest and end with the highest value in the series - if this is the case, perhaps there's no value to achieve the running total with this method with my real data (the demo file had mock data in)

If someone is familiar with the correct way to use these two formulas as I'm having some difficult. I used the following formula (successfully!) to create a running total calculated column (of time stored as a decimal number):

=List.Sum(List.Range(#Added Index"[TimePerCase],0,[Index]))

However, replicating the conditions & the formula to another situation has made the formula come back with Error. I've checked this isn't to do with the data type I am referring to in each case.

The error message reads that [TimePerCase] is not a 'list' data type. However, the values in both situations are effectively the same. The [TimePerCase] are small decimals around 0.00001. The other workbook interpreted these values as a 'list'.

Does anyone know what might be causing my error? Thanks

EDIT: Does 'List' have a maximum number of records? My current PQ is around 16k rows.

EDIT: Another idea... I believe lists need to start with the lowest and end with the highest value in the series - if this is the case, perhaps there's no value to achieve the running total with this method with my real data (the demo file had mock data in)