# How to use select box relating with database(oracle) in ruby on rails

**URL:** <https://www.ruby-forum.com/t/how-to-use-select-box-relating-with-database-oracle-in-ruby-on-rails/127578>\
**Category:** Rails\
**Created:** [January 30, 2008, 3:21pm UTC](https://www.ruby-forum.com/t/how-to-use-select-box-relating-with-database-oracle-in-ruby-on-rails/127578 "2008-01-30T15:21:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![napster](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/65b543/32.png) [@napster](https://www.ruby-forum.com/u/napster)\
**Post date:** [January 30, 2008, 3:21pm UTC](https://www.ruby-forum.com/t/how-to-use-select-box-relating-with-database-oracle-in-ruby-on-rails/127578/1 "2008-01-30T15:21:04Z")

</div>

hi guys

i am using ruby on rails since 2months and the version for rails is  
2.0.2 and the editor using is APTANA IDE and the problem is i have to  
use selection box in a page so that when i click on any one of the  
items in that selection box it will show the details of the related  
item in another select box.

for that i created two models one is  
category(category\_id,category\_type) and another is tech\_type.And how  
to write code in controller and view to get the result
