I have a large database import I am working with that is several tables of data that have to be combined into one master spreadsheet(csv) for import.

There is a primary key with both tables but both tables are missing numbers say the order is 11-83529 but neither table is completely sequential.

The only solution I have found the works on that column is to fill - series choosing linear and using the line numbers.

However I need to act that way on the whole , adding a row each time it finds a missing number and adding the number to the first column? Does anyone know how to do this?