Hello,
Is there a way to find the first of in a datasubset? For example I have a datasubset with 5 records. The 4th record has an id=null. If I pass in a datasubset and where id=null, it would return the index of 4. How would I approach creating an expression for this? Thanks
Discussion posts and replies are publicly visible
Hi Miked,I hope this code will help you.
load( local!pagingInfo: a!pagingInfo( startIndex: 1, batchSize: - 1 ), local!datasubset: todatasubset( { { id: 1, firstName: "A" }, { id: 2, firstName: "B" }, { id: 3, firstName: "C" }, { id: null, firstName: "D" }, { id: 5, firstName: "E" } }, local!pagingInfo ), index( local!datasubset.data, wherecontains( tointeger( null() ), tointeger( local!datasubset.data.id ) ), {} ))