Ask a Question related to ASP Database, Design and Development.
-
Spinner #1
ASP form writing to multiple DB tables.
I'm new to Access and ASP pages, but so far I have been doing OK.
This one has me stumped.
What I am trying to do is have an ASP form with several dropdown lists,
all pulling the same data from an Access DB table.
The goal is to allow the end user to make multiple selections, 1 from each
dropdown
and have the results written to another table.
Sort of like this.
tblChoices contains 3 entries. choice1, choice2, choice3.
Form would have 3 drop down lists, each displaying the 3 choices from
tblchoices.
tblchoices will have more entries added by another form, that is why I don't
just hard code it.
choice1 choice1 choice1
choice2 choice2 choice2
choice3 choice3 choice3
I want them to be able to give one selection from each column,
then have the results written to tblResults.
I just can't seem to get it to work. It works fine using only 1 dropdown,
but
any others added will not pull data from the DB.
Maybe this is not even the correct way to do this, If you have a suggestion
I am all ears. And while I am here, is there any way to have 1 form field
write to more then 1 table and or record? (using an ASP webpage)
Spinner Guest
-
update multiple records in multiple tables from one form
hello I have been trying to run multiple update queries based on the data entered by user. Brief background: I am fetching data from various... -
Can one <form> submit data to multiple tables?
Am I able to use a single form to write data to multiple tables in my database using php/mySQL? -
How do you delete a record form multiple tables
I have a dbase that has about 30 tables in it. How can I delete a record out of all of the tables without doing 30 DELETE statements? Example:... -
writing db record to tables (wrapping and spanning rows)
Hi, I have a dataset where each record contains a persons name and filename of their picture. I want to write a row of five names, then a row... -
Writing multiple sessions to DVD?
I've got a new machine with a DVD burner, and I've never used the built-in burning features of OS X, so I'm wondering how it works. I'd like to... -
Ken Schaefer #2
Re: ASP form writing to multiple DB tables.
<%
Set objRS = objConn.Execute
If not objRS.EOF then
arrResults = objRS.GetRows
End If
' Clean up ADO objects here
%>
'
'
'
<%
If isArray(arrResults)
For i = 1 to 3
%>
<select name="cbo_<%=i%>">
<%For j = 0 to UBound(arrResults, 2)%>
<option><%=arrResults(0,i)%></option>
<%Next%>
</select>
<%
Next
End If
%>
HTH
Cheers
Ken
"Spinner" <spinner@theweb.cor> wrote in message
news:OLI46lNfDHA.2348@TK2MSFTNGP12.phx.gbl...
: I'm new to Access and ASP pages, but so far I have been doing OK.
: This one has me stumped.
: What I am trying to do is have an ASP form with several dropdown lists,
: all pulling the same data from an Access DB table.
: The goal is to allow the end user to make multiple selections, 1 from each
: dropdown
: and have the results written to another table.
:
: Sort of like this.
:
: tblChoices contains 3 entries. choice1, choice2, choice3.
: Form would have 3 drop down lists, each displaying the 3 choices from
: tblchoices.
: tblchoices will have more entries added by another form, that is why I
don't
: just hard code it.
:
: choice1 choice1 choice1
: choice2 choice2 choice2
: choice3 choice3 choice3
:
: I want them to be able to give one selection from each column,
: then have the results written to tblResults.
:
: I just can't seem to get it to work. It works fine using only 1 dropdown,
: but
: any others added will not pull data from the DB.
: Maybe this is not even the correct way to do this, If you have a
suggestion
: I am all ears. And while I am here, is there any way to have 1 form field
: write to more then 1 table and or record? (using an ASP webpage)
:
:
:
:
Ken Schaefer Guest
-
Spinner #3
Re: ASP form writing to multiple DB tables.
Thanks.!
I got it working now.
"Ken Schaefer" <kenREMOVE@THISadOpenStatic.com> wrote in message
news:eGnYK6NfDHA.2984@TK2MSFTNGP11.phx.gbl...each> <%
> Set objRS = objConn.Execute
>
> If not objRS.EOF then
> arrResults = objRS.GetRows
> End If
>
> ' Clean up ADO objects here
> %>
> '
> '
> '
> <%
> If isArray(arrResults)
> For i = 1 to 3
> %>
>
> <select name="cbo_<%=i%>">
> <%For j = 0 to UBound(arrResults, 2)%>
> <option><%=arrResults(0,i)%></option>
> <%Next%>
> </select>
> <%
> Next
> End If
> %>
>
> HTH
>
> Cheers
> Ken
>
> "Spinner" <spinner@theweb.cor> wrote in message
> news:OLI46lNfDHA.2348@TK2MSFTNGP12.phx.gbl...
> : I'm new to Access and ASP pages, but so far I have been doing OK.
> : This one has me stumped.
> : What I am trying to do is have an ASP form with several dropdown lists,
> : all pulling the same data from an Access DB table.
> : The goal is to allow the end user to make multiple selections, 1 fromdropdown,> : dropdown
> : and have the results written to another table.
> :
> : Sort of like this.
> :
> : tblChoices contains 3 entries. choice1, choice2, choice3.
> : Form would have 3 drop down lists, each displaying the 3 choices from
> : tblchoices.
> : tblchoices will have more entries added by another form, that is why I
> don't
> : just hard code it.
> :
> : choice1 choice1 choice1
> : choice2 choice2 choice2
> : choice3 choice3 choice3
> :
> : I want them to be able to give one selection from each column,
> : then have the results written to tblResults.
> :
> : I just can't seem to get it to work. It works fine using only 1field> : but
> : any others added will not pull data from the DB.
> : Maybe this is not even the correct way to do this, If you have a
> suggestion
> : I am all ears. And while I am here, is there any way to have 1 form> : write to more then 1 table and or record? (using an ASP webpage)
> :
> :
> :
> :
>
>
Spinner Guest



Reply With Quote

