cancel
Showing results for 
Search instead for 
Did you mean: 

Facing a weird issue with collection in 7.3.1

Hi team,

I'm facing a weird issue when extracting a field value from a collection using simple dot notation.

See the snaps below. The collection has data and values, but in the calc stage, all the fields are showing empty values. If I run then it also throws error.

To note this is outside the loop. Post loop completion I'm using a calc stage to grab a value. If I perform the same before the loop, calc stage works fine.

Tejaskumar_Darji_1-1728056824578.png

In Collection I can see value

Tejaskumar_Darji_2-1728056861896.png

 

Tejaskumar_Darji_0-1728056722531.png

Tejaskumar_Darji_3-1728057000704.png

 

 

1 REPLY 1

david.l.morris
Level 15

Hi @Tejaskumar_Darji,

Anytime a collection says "# Row" or "# Rows", you can't use an expression to reference a field in it because no row is selected. The reason it works before the loop is that by default Row 1 is selected. If you only have one row, then it can lead you to think something is wrong here when you try to use a calc after the loop, but it's always functioned like this I think. I tested it in 7.3.1 and 6.10.1 just to make sure I'm not crazy, and I see the same behavior in both. I get an error in the calc stage after the loop saying the collection has no current row.

As for the other issue you mentioned where the calc stage appears to be empty, did you try setting the value into a data item? I am guessing it shows empty for you where it says Temporary Values because that's just what it does if you don't have a current row selected, such as once you leave the loop. I tested this in 7.3.1, and during the loop for me it gets the value.

davidlmorris_0-1728066917663.png

 


Dave Morris, 3Ci at Southern Company