Need to map dynamic data that changes from SQL query

I’m going to try and explain this as best I can so bear with me. I’m doing this in the REF just for reference.

I have to make an SQL query that queries data (customer account information) from a database table. I take that table, put it in a data table and then save it on a shared drive. The policy number is then added an orchestrator queue.

Next, I have to extract the data from the spreadsheet and enter it into an online form which then saves it.

What I was doing was simply reading the cells in the spreadsheet and assigning variables to those cells and then filling in the form data. The problem is now with different queries, the data is no longer in the same cells so when uipath is reading the cells, its often times getting the wrong data and entering the wrong data into the wrong field in the forms.

Is there a way for me to save the spreadsheet and map the data, then assign a variable to the newly mapped data and then enter it into the forms?