# (unknown)

**URL:** <https://rubytalk.org/t/unknown/28834>\
**Category:** ruby-talk\
**Created:** [10 July 2006 22:05 UTC](https://rubytalk.org/t/unknown/28834 "2006-07-10T22:05:52Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ali](https://avatars.discourse-cdn.com/v4/letter/a/8c91f0/32.png) [@Ali](https://rubytalk.org/u/Ali)\
**Post date:** [10 July 2006 22:05 UTC](https://rubytalk.org/t/unknown/28834/1 "2006-07-10T22:05:52Z")

</div>

HELP

Hi,

I'm a Ruby on Rails newbie. I've been tasked with building our office's  
first ROR application, and I am the only one working on it, so I am  
muddling through with a couple of books... Moving along slowly but need  
some discussion time with some people who KNOW it and can maybe offer  
some answers to questions I haven't found in my books.

First - what is the fundamental difference between "render" and  
"redirect\_to" when working with .rhtml forms in the Controller? When is  
it appropriate to use these?

Second - Why do I sometimes have to use a while loop to access my  
queried data in the .rhtml form? Example:

Controller-Edit Method

@edit = Cause.find(:all, :conditions =\> "case\_id = '#{@caseid}'")

View-Edit.rhtml

\<h2\>Editing Case \<%= @edit.case\_id %\>

This method of data retrieval has worked for me in other similar forms,  
and I can't figure out why it won't work here. The error it gives is  
that case\_id is not a valid method, but it is a valid field in the  
table, so should work. (case\_id is the foreign key for the table)

However, if I put the data retrieval inside a while loop, it displays  
the data, but gives me a routing error when I try to update.

I have other questions as well, but I guess I'll start here. ANY AND  
ALL tips, advice, etc. would be greatly appreciated!!

Thank you,

Ali Williams

Systems Developer II

Washoe County IT

775 328-3720

 ![](https://canada1.discourse-cdn.com/flex029/uploads/rubytalk/original/1X/0bcb014b2222ead38cec4b117693e674d81b27d6.jpg)

---

<div class="post-metadata">

**Author:** ![Phillip\_Hutchings](https://avatars.discourse-cdn.com/v4/letter/p/f08c70/32.png) [@Phillip\_Hutchings](https://rubytalk.org/u/Phillip_Hutchings)\
**Post date:** [10 July 2006 22:09 UTC](https://rubytalk.org/t/unknown/28834/2 "2006-07-10T22:09:23Z")

</div>

Firstly, you want the Rails list at  
[http://lists.rubyonrails.org/mailman/listinfo/rails](http://lists.rubyonrails.org/mailman/listinfo/rails), and secondly you  
want to stop using Comic Sans MS for emails. Send plain text, it gets  
though lists better.

> **···**
>
> --  
> Phillip Hutchings  
> [http://www.sitharus.com/](http://www.sitharus.com/)

---

<div class="post-metadata">

**Author:** ![Christian\_Neukirche1](https://avatars.discourse-cdn.com/v4/letter/c/ee7513/32.png) [@Christian\_Neukirche1](https://rubytalk.org/u/Christian_Neukirche1)\
**Post date:** [11 July 2006 20:34 UTC](https://rubytalk.org/t/unknown/28834/3 "2006-07-11T20:34:32Z")

</div>

"Phillip Hutchings" \<sitharus@sitharus.com\> writes:

> Firstly, you want the Rails list at  
> [http://lists.rubyonrails.org/mailman/listinfo/rails](http://lists.rubyonrails.org/mailman/listinfo/rails), and secondly you  
> want to stop using Comic Sans MS for emails. Send plain text, it gets  
> though lists better.

And specify a subject.

> **···**
>
> > Phillip Hutchings
> 
> --  
> Christian Neukirchen \<chneukirchen@gmail.com\> [http://chneukirchen.org](http://chneukirchen.org)
