I have a VBScript that converts a RecordSet to an Array, and now I'm attempting to make it more "readable" for me when accessing items out of the array.
Right now, I'm setting variables based on where the items are returning in the array:
Variable1 = arrRS(0,i)
Variable2 = arrRS(1,i)
Variable3 = arrRS(2,i)
Right now, my fear is that at some point the RS order could change, and I'd have to revisit this code and figure out what columns represented what data all over again.
I'd like to return the code to how it handled itself when everything was still a RecordSet, where I could call data by it's column title in the record set. I know Array's don't support this natively, but I'd like to do something as identified in the last post in this page:
Unfortunately, I have absolutely now idea on the code that would be needed to make that happen. IE, grab the titles from the RecordSet, then throw them into an Array. Match the data that I stream from the original RecordSet, and pair the column number up with column title, then use that information to reference the data that's needed. If this is even possible.
Would somebody be able to point me in the right direction?