Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Form plus...

1 view
Skip to first unread message

trs.net

unread,
Aug 15, 2004, 2:51:51 PM8/15/04
to
I have a poll/survey question that appears on a dynamically created page.
The question is appearing like its supposed to AND the form part, to answer
the poll question is also appearing like its supposed to. HOWEVER, When I
submit the form, the data is not being entered into my database table!

Here's my code below, that I use to get the question to appear on the page.
Keep in mind, I have the question and the answers in separate db tables. Is
that OK? I figure it is and that I'm missing something simple.

<cfquery name="Qs" datasource="datainfo.mdb" username="imwebguy"
password="smacktag">
SELECT dbo.trs_test_poll.CategoryQ, dbo.trs_test_poll.PollQID,
dbo.trs_test_poll.Question, dbo.trs_category.CategoryID,
dbo.trs_category.Category
FROM dbo.trs_test_poll, dbo.trs_category
WHERE dbo.trs_test_poll.CategoryQ = dbo.trs_category.CategoryID
AND dbo.trs_category.CategoryID=#URL.CategoryID#
</cfquery>

My form looks like this:
Question? ---which comes from one db table
Then, below, you click either a Yes No radio button
And enter comments into a text area.
Then enter your email into a text field.
Then click submit.

The question comes from one db table and the answers are entered into another
db table. What I need to accomplish is to get the ID from the Question db to
be entered into the Answer db table.

Please help!
Thanks in advance!

webfor...@macromedia.com

unread,
Aug 16, 2004, 11:32:01 AM8/16/04
to
Isn't "dbo.trs_test_poll.PollQID" the ID that you want? Assign it to a
variable (session/form) and then write it to the database. What do you mean
when you say that the data is not being entered into the database table? Do
you have an insert sql statement on the action page?

Chris

0 new messages