# Form issue

**URL:** <https://www.ruby-forum.com/t/form-issue/78590>\
**Category:** Ruby\
**Created:** [March 8, 2006, 7:05pm UTC](https://www.ruby-forum.com/t/form-issue/78590 "2006-03-08T19:05:50Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![chadmaester](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/67e7ee/32.png) [@chadmaester](https://www.ruby-forum.com/u/chadmaester)\
**Post date:** [March 8, 2006, 7:05pm UTC](https://www.ruby-forum.com/t/form-issue/78590/1 "2006-03-08T19:05:50Z")

</div>

I have a dilema. I have an HTML form which is in a test format, and the  
form has multiple questions, and each question has multiple radio  
buttons. I need a way to distinguish which question each set of radio  
buttons belongs to, and I can’t think of a way to do this.

This is basically what the form looks like:

Question #1

Question #2

And this is the database table the test results are being saved to:

survey\_results  
id : int  
student\_id : int  
question\_id : int  
answer : int

Is there a way to somehow hardcode what the value of the question\_id  
field for each question should be? What can I do?
