Let's say I have two tables with data from the same table in my database.
The only difference is that my sql query that feeds them applies a WHERE on a column that is not the same.
Is it possible to feed inputs by letting the user choose which table he wants (using table1. selectedrow.etc). Here is a draw (best skills on Paint ever) of what i'm looking for :
Event handler on row selection set temp state with the data you want to populate into fields. Make the temp state the same for both tables and it will overwrite on selection. Then set the defaults for the fields to be the temp state.
Will "or" work in an input like that? I've never tried it that's interesting. How will it work if each table has a selected row? Setting a temp state that gets overwritten is more steps but seems much more foolproof.