Apologies for reposting this, but many people just see a post with lots of replies as being solved so I have re-posted it.
Anyways, apologies once again, but here it is with more of an explanation.
------------------------------------------------
Lets say 1 table contains 5 fields:
table_id
table_main_1
table_main_2
table_main_3
table_main_4
Do the usual methods to get the data then assign the data to the variables. As you can see the names of the variables take their name from the field name:
table_id = objRecordSet("table_id"![Wink ;) ;)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
table_main_1 = objRecordSet("table_main_1"![Wink ;) ;)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
table_main_2 = objRecordSet("table_main_2"![Wink ;) ;)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
table_main_3 = objRecordSet("table_main_3"![Wink ;) ;)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
table_main_4 = objRecordSet("table_main_4"![Wink ;) ;)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
Now instead of having to do the above assigning bit manually, I just want to be able to just change the SQL statement and it will dynamically build the above using the field names as the names of the variables and the field content as the data assigned to each variable. Is this possible, and if so which is the best way around this.
Just as a note I dont really want to use sessions though, as it is quite resource intensive.
------------------------------------------------ - FateFirst
Anyways, apologies once again, but here it is with more of an explanation.
------------------------------------------------
Lets say 1 table contains 5 fields:
table_id
table_main_1
table_main_2
table_main_3
table_main_4
Do the usual methods to get the data then assign the data to the variables. As you can see the names of the variables take their name from the field name:
table_id = objRecordSet("table_id"
table_main_1 = objRecordSet("table_main_1"
table_main_2 = objRecordSet("table_main_2"
table_main_3 = objRecordSet("table_main_3"
table_main_4 = objRecordSet("table_main_4"
Now instead of having to do the above assigning bit manually, I just want to be able to just change the SQL statement and it will dynamically build the above using the field names as the names of the variables and the field content as the data assigned to each variable. Is this possible, and if so which is the best way around this.
Just as a note I dont really want to use sessions though, as it is quite resource intensive.
------------------------------------------------ - FateFirst