Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2000-12-14 : 16:07:18
|
B writes "Is there any way to "easily" pull the name of each column into an array with the recordset? So, if I was to create a recordset, and use .getRows() to pull it into an array, can I also pull the column names in with the record data?
It sounds kind of dumb, but in the application I am building, I always wind up having 2 arrays...one of field names and one of strictly data.
Now I know that I can loop through the recordset to pull the name of each field, and then put these elements, one by one, into the recordset array. However, I would have to do this after I create the recordset array because .getRows does not permit assigning the .getRows result to a previously declared array. I am not very thrilled about running through the recordset(s) to pull out the field names, especially when each recordset might return 50 or more fields.
My current method works, but I am curious if there is a better method to do it.
-B" |
|
|
|
|