Hi,

I want to find the index of no of occurance of a each value (posting key) in the datatable. For example: for the below scenario

Index Posting Key

1 - 40

1 - 19

2 - 40

2 - 19

There are 4 known posting keys, so for each posting key I have to find the index from the datatable.

Please let me know how to achieve this. Thank you

Also, the current method I implemented:

I assigned a variable “index” to “datatable.rows.indexof(row)”

Another variable “posting_key” to "datatable.rows(index)(“Posting Key”).tostring

This gives me

Index Posting Key

1 - 40

2 -19

3-40

4-19

Can I put a where condition in the above formula itself to get index for individual posting keys like below?

Index Posting Key

1 - 40

1 - 19

2 - 40

2 - 19