I have this problem where I’m trying to insert into 2 tables. As you can see from the code, I can successfully insert into tblConsignments, but I cannot insert into tblSender and tblReceiver. If you scroll to the bottom, I’ve put the form details that I need inserted.
Any help would be much appreciated.
I have 2 tables, one for tblsender and one for tblreceiver.
They both have exactly the same fields
CustomerID (AutoNumber)
ConsignmentID
Name
Address
WorkNo
HomeNo
Mobile
email
So basically, how do I write the Insert statement so both details from sender and receiver are inserted into tblSender and tblReceiver when the Add button is clicked?. If you can please show me in the context of my below code, then that would be much appreciated.
Thankyou in advance
——————————-
Consignment ID | <input type="text" size="1" disabled name="x_ConsignmentID" value="” | <input type="text" name="x_ConsignmentID" value="” size=50 maxlength=50> |
Destination |
<% response.write "” & RS(“Destination”) & “” RS.MoveNext Response.Write “” SQL = “SELECT * FROM tblOrigin WHERE initial = ‘” & Session(“userid”) & “‘” If RS.EOF = False Then Conn.Close | |
Status | ||
<INPUT TYPE="Radio" NAME="x_Status" VALUE=”0″ checked > | ||
Origin | <input type="text" name="x_Origin" value="” disabled size=30 maxlength=50> <input type="hidden" name="x_Origin" value="” size=30 maxlength=50> |
|
Type | <% x_TypeList = "” x_TypeList = x_TypeList & “” & “” & “” x_TypeList = x_TypeList & “” & “Document” & “” x_TypeList = x_TypeList & “” & “Parcel” & “” x_TypeList = x_TypeList & “” response.write x_TypeList %> |
|
Description | ||
Remarks | ||
Depart Date | <input type="hidden" name="x_DepartDate" size=25 value=" “> |
Sender Details
Name:
Business:
Address:
Work No:
Home No:
Mobile No:
Email:
Receiver Details
Name:
Business:
Address:
Work No:
Home No:
Mobile No:
Email:
—————————–