Forums
This topic is locked
Forms Help Needed Badly
Posted 28 Jul 2003 00:36:52
1
has voted
28 Jul 2003 00:36:52 Cathy French posted:
I am using DreamweaverMX, Asp VBScript and SQL 2000 db. I have two tables set up. Both have primary keys tb1_ID, tb2_ID, with the foreign key of tb1_ID in table 2. All the information on these forms are input by the user.Is there a way to insert the value of the Primary key in tb1 into the referenced column (foreign key) in table2 dynamically without the user having any interface with ID values?)
I cannot list the names associated with the value and have them choose, because 1. there are too many and 2) the user should not have knowledge of the other names.
I hope this makes sense.
Basically, I just want to populate the primary key value of one table into the foreign key value of the second table without user's knowledge.
Can someone help?
Replies
Replied 28 Jul 2003 10:15:17
28 Jul 2003 10:15:17 Lee Diggins replied:
Hi
When you retrieve the tbl1 pk data, put this value in a hidden field on your form, then, when you do your INSERT into tbl2 reference the hidden field value.
Digga
Sharing Knowledge Saves Valuable Time!!!
When you retrieve the tbl1 pk data, put this value in a hidden field on your form, then, when you do your INSERT into tbl2 reference the hidden field value.
Digga
Sharing Knowledge Saves Valuable Time!!!