AG Grid Event Handling with Custom Row Identifiers

I’m using AG Grid with data from a cloud PostgreSQL database loaded into a Pandas DataFrame. My goal is to use a column named unique_id as the primary row identifier. The problem is that AG Grid keeps returning rowIndex during events like on_cell_value_changed . Since rowIndex changes dynamically whenever filtering occurs, it causes issues linking back to my database.

I need AG Grid to use unique_id consistently for row identification, even when filtering or sorting is applied, to ensure accurate backend synchronization.

Request

How can I properly configure AG Grid to use unique_id as the row identifier instead of rowIndex , so the correct row is referenced during cell change events regardless of filtering or sorting?

1 Like

I had the same problem with editing.

I created an issue a short while ago to track it at: AgGrid needs to pass more than just row number when editing · Issue #25 · reflex-dev/reflex-ag-grid · GitHub

1 Like

Many thanks Bert,

I hope Reflex team can provide a solution or a fix.

@Lendemor

Do you think this could be wrapped up as an activity before the year ends?

If you ask me, it’d be the ultimate Christmas gift—talk about a :christmas_tree::santa: mic drop!

1 Like

Hi everyone! Just checking in to see if there’s a potential ETA for this fix or if it might be a particularly challenging one to tackle?

I truly appreciate the effort everyone puts into resolving these issues and understand priorities can shift. I just wanted to gently bump this topic to see if there’s any update or additional insight.

Thanks so much for your time and help! :clap:

1 Like