I want to replace an iterative loop by using a query of columns from a "Data Dictionary" table, linked to a regular data table to insert a number of values at once into a history table, rather than run through each field in the recordset, compare it to its previous value and insert it individually into the history table.
The problem, is I can't find a system table like SQL Server's "syscolumns" or information_schema.columns tables to use. The only alternative, I see is to build my own columns table, populate it from the .TableDefs.(x).Fields collections and maintain it as tables change. I would really prefer not to have to implement it this way.
Please let me know if there is a way to query the column names of a table, rather than iterate through them from the Fields collection.
The reason for the change is to improve the performance of my system. It seems to me one larger SQL insert statement should run much faster than iterating through several smaller ones.
The problem, is I can't find a system table like SQL Server's "syscolumns" or information_schema.columns tables to use. The only alternative, I see is to build my own columns table, populate it from the .TableDefs.(x).Fields collections and maintain it as tables change. I would really prefer not to have to implement it this way.
Please let me know if there is a way to query the column names of a table, rather than iterate through them from the Fields collection.
The reason for the change is to improve the performance of my system. It seems to me one larger SQL insert statement should run much faster than iterating through several smaller ones.