# Rails

**URL:** https://www.ruby-forum.com/c/ruby-on-rails/6.md?page=828

[Latest](https://www.ruby-forum.com/latest.md) · [Categories](https://www.ruby-forum.com/categories.md) · [Tags](https://www.ruby-forum.com/tags.md)

**Page:** 829

---

## [Adding hashes to array: bad value](https://www.ruby-forum.com/t/adding-hashes-to-array-bad-value/174506)

<div class="topic-metadata">

**Author:** [@aldoitalo](https://www.ruby-forum.com/u/aldoitalo)\
**Replies:** 0\
**Last updated:** [August 27, 2009, 8:50pm UTC](https://www.ruby-forum.com/t/adding-hashes-to-array-bad-value/174506 "2009-08-27T20:50:40Z")

</div>

hi, i want to implemnt a system for display recurrent events, i startly with a embrional code: ######### on my DB i have 1 record: { :title =\> “example”, :repeat\_day =\> “4” } ######### on my controller: @repetition…

---

## [Picture Slideshow using a database](https://www.ruby-forum.com/t/picture-slideshow-using-a-database/174469)

<div class="topic-metadata">

**Author:** [@tdellaringa](https://www.ruby-forum.com/u/tdellaringa)\
**Replies:** 1\
**Last updated:** [August 27, 2009, 6:39pm UTC](https://www.ruby-forum.com/t/picture-slideshow-using-a-database/174469 "2009-08-27T18:39:07Z")

</div>

On my site, I am having a sort of slideshow in which people can purchase the ability to put a picture on. It’s sort of a one shot deal thing, in which someone can go on and navigate to a page that allows them to pick …

---

## [Goldberg](https://www.ruby-forum.com/t/goldberg/174400)

<div class="topic-metadata">

**Author:** [@braulio](https://www.ruby-forum.com/u/braulio)\
**Replies:** 3\
**Last updated:** [August 27, 2009, 5:15pm UTC](https://www.ruby-forum.com/t/goldberg/174400 "2009-08-27T17:15:22Z")

</div>

Hi All, Anyone know of any component or plugin like Goldberg? Thanks BrÃ¡ulio Lima.

---

## [Question regarding routing](https://www.ruby-forum.com/t/question-regarding-routing/174468)

<div class="topic-metadata">

**Author:** [@dhruvasagar](https://www.ruby-forum.com/u/dhruvasagar)\
**Replies:** 1\
**Last updated:** [August 27, 2009, 4:50pm UTC](https://www.ruby-forum.com/t/question-regarding-routing/174468 "2009-08-27T16:50:48Z")

</div>

Hi Everyone, I am developing a small web application using rails, in my controller I have added a function which is apart from the normal one’s that are supported by the default routes, hence to map this one as well…

---

## [Help - Status: 500 Internal Server Error unknown error](https://www.ruby-forum.com/t/help-status-500-internal-server-error-unknown-error/174441)

<div class="topic-metadata">

**Author:** [@mgpowers](https://www.ruby-forum.com/u/mgpowers)\
**Replies:** 4\
**Last updated:** [August 27, 2009, 3:20pm UTC](https://www.ruby-forum.com/t/help-status-500-internal-server-error-unknown-error/174441 "2009-08-27T15:20:38Z")

</div>

I get the default web page served up by WebBrick on Windows ok but if I click on Application enviroment or try to view my html from a controller I get the following error message in my log… Any ideas ? /!\\ FAILSAFE …

---

## [Deleting table data from staging table](https://www.ruby-forum.com/t/deleting-table-data-from-staging-table/174448)

<div class="topic-metadata">

**Author:** [@jmaenpaa](https://www.ruby-forum.com/u/jmaenpaa)\
**Replies:** 4\
**Last updated:** [August 27, 2009, 2:57pm UTC](https://www.ruby-forum.com/t/deleting-table-data-from-staging-table/174448 "2009-08-27T14:57:10Z")

</div>

Hello all, I’m using Ruby 1.8.6 and Rails 2.3.3. I’m new at Rails so bear with me, please. My application reads in a csv file to a staging (imports) table then compares the contents of the table to a main (projects) …

---

## [Who is Why? And why he disappeared?](https://www.ruby-forum.com/t/who-is-why-and-why-he-disappeared/174484)

<div class="topic-metadata">

**Author:** [@sijo](https://www.ruby-forum.com/u/sijo)\
**Replies:** 1\
**Last updated:** [August 27, 2009, 2:27pm UTC](https://www.ruby-forum.com/t/who-is-why-and-why-he-disappeared/174484 "2009-08-27T14:27:13Z")

</div>

Hi Have you read this? Why this person vanished?Anyone knows? And actually who is he? Why did he do that? Please share your thoughts Sijo

---

## [Automating online banking login & checking for new transactions - what's best approach? (e.g. which](https://www.ruby-forum.com/t/automating-online-banking-login-checking-for-new-transactions-whats-best-approach-e-g-which/174490)

<div class="topic-metadata">

**Author:** [@greghauptmann](https://www.ruby-forum.com/u/greghauptmann)\
**Replies:** 0\
**Last updated:** [August 27, 2009, 1:52pm UTC](https://www.ruby-forum.com/t/automating-online-banking-login-checking-for-new-transactions-whats-best-approach-e-g-which/174490 "2009-08-27T13:52:51Z")

</div>

Hi, I’m interested in automating online banking login & checking for new transactions - what’s best approach? (e.g. which gems/libraries etc) Anyone already built something that does this? For example login each hour…

---

## [What is the best server for RoR?](https://www.ruby-forum.com/t/what-is-the-best-server-for-ror/174488)

<div class="topic-metadata">

**Author:** [@railshouse](https://www.ruby-forum.com/u/railshouse)\
**Replies:** 0\
**Last updated:** [August 27, 2009, 1:48pm UTC](https://www.ruby-forum.com/t/what-is-the-best-server-for-ror/174488 "2009-08-27T13:48:10Z")

</div>

Hi all, I have been deploying my RoR application on EC2 server and most frequently i get “500 server internal problem .” error . I figured it out this happens when number of user increase above 10.Could anyone pleas…

---

## [Forcing selected item in select](https://www.ruby-forum.com/t/forcing-selected-item-in-select/174486)

<div class="topic-metadata">

**Author:** [@RVince](https://www.ruby-forum.com/u/RVince)\
**Replies:** 0\
**Last updated:** [August 27, 2009, 1:26pm UTC](https://www.ruby-forum.com/t/forcing-selected-item-in-select/174486 "2009-08-27T13:26:30Z")

</div>

How do I make sure item 0 is selected in: \<%= select(“channelnotes”, “channelnotes”, Channelnote.find (:all, :order =\> ‘tstamp DESC’, :limit =\>3, :conditions =\> \[“deleted=0”\]).collect {|p| \[ p.note, p.note\]}, { :incl…

---

## [Noob DRY method question](https://www.ruby-forum.com/t/noob-dry-method-question/174408)

<div class="topic-metadata">

**Author:** [@Dudebot](https://www.ruby-forum.com/u/Dudebot)\
**Replies:** 5\
**Last updated:** [August 27, 2009, 11:06am UTC](https://www.ruby-forum.com/t/noob-dry-method-question/174408 "2009-08-27T11:06:35Z")

</div>

Hi Gurus, I’m learning the Rails framework, and I have this exact block of html/javascript in two places in an if/else construct in application.html.erb: Trying to be DRY, I’d like to put that html/javascript somewhe…

---

## [How to include module's class in controller?](https://www.ruby-forum.com/t/how-to-include-modules-class-in-controller/174410)

<div class="topic-metadata">

**Author:** [@vikas](https://www.ruby-forum.com/u/vikas)\
**Replies:** 2\
**Last updated:** [August 27, 2009, 10:33am UTC](https://www.ruby-forum.com/t/how-to-include-modules-class-in-controller/174410 "2009-08-27T10:33:47Z")

</div>

Hello all, I have a module that contains a class as following my\_module.rb module MyModule class MyClass \< OtherClass def my\_method(value) #process value return value end end end In my controller class MyContro…

---

## [DB / App Best Practice](https://www.ruby-forum.com/t/db-app-best-practice/174451)

<div class="topic-metadata">

**Author:** [@brianp](https://www.ruby-forum.com/u/brianp)\
**Replies:** 1\
**Last updated:** [August 27, 2009, 10:20am UTC](https://www.ruby-forum.com/t/db-app-best-practice/174451 "2009-08-27T10:20:19Z")

</div>

Hey Everyone. Just wondering what I should do in regard to how much data (what type of data) to store in the db. If I have a table of cars: –cars– id - PK type color In regards to the color is it best to just stor…

---

## ['ruby script/server' responds with: "Missing the Rails gem. ..." \<-- not true. Why?](https://www.ruby-forum.com/t/ruby-script-server-responds-with-missing-the-rails-gem-not-true-why/174450)

<div class="topic-metadata">

**Author:** [@ric](https://www.ruby-forum.com/u/ric)\
**Replies:** 3\
**Last updated:** [August 27, 2009, 10:10am UTC](https://www.ruby-forum.com/t/ruby-script-server-responds-with-missing-the-rails-gem-not-true-why/174450 "2009-08-27T10:10:22Z")

</div>

Here’s my environment (Mac OS X 10.5.8): \[/Users/Ric/workarea/rails/demo\]ruby --version ruby 1.9.1p0 (2009-01-30 revision 21907) \[i386-darwin9\] \[/Users/Ric/workarea/rails/demo\]rails --version Rails 2.3.3 \[/Users/Ric…

---

## [HABTM for 3 different tables](https://www.ruby-forum.com/t/habtm-for-3-different-tables/174476)

<div class="topic-metadata">

**Author:** [@akramwasim1234](https://www.ruby-forum.com/u/akramwasim1234)\
**Replies:** 0\
**Last updated:** [August 27, 2009, 9:47am UTC](https://www.ruby-forum.com/t/habtm-for-3-different-tables/174476 "2009-08-27T09:47:32Z")

</div>

Hi Everybody, I’m having 3 tables 1)Insurance 2)policy 3) Users and all have has and belongs to many relationships I want to link all this 3 tables . Plz guide me on how to link all these table using HABTM

---

## [Capistrano error.. can't use sudo](https://www.ruby-forum.com/t/capistrano-error-cant-use-sudo/174372)

<div class="topic-metadata">

**Author:** [@spacechurro](https://www.ruby-forum.com/u/spacechurro)\
**Replies:** 2\
**Last updated:** [August 27, 2009, 9:34am UTC](https://www.ruby-forum.com/t/capistrano-error-cant-use-sudo/174372 "2009-08-27T09:34:01Z")

</div>

i am having a problem getting capistrano to run my deployment… it’s trying to sudo run the spin script, and this client does not have sudo privileges… i have added the following lines to my deployment.rb set :user\_su…

---

## [Can't get rcov to work. 0 assertions returned](https://www.ruby-forum.com/t/cant-get-rcov-to-work-0-assertions-returned/174475)

<div class="topic-metadata">

**Author:** [@uberllama](https://www.ruby-forum.com/u/uberllama)\
**Replies:** 0\
**Last updated:** [August 27, 2009, 8:14am UTC](https://www.ruby-forum.com/t/cant-get-rcov-to-work-0-assertions-returned/174475 "2009-08-27T08:14:36Z")

</div>

Hi folks. First post on these forums, after finally giving up on railsforum.com. I recently installed the relevance fork of rcov and am having no luck at all. sudo gem install relevance-rcov Easy enough. Everything …

---

## [Unable to create record with has\_mant :through relationship](https://www.ruby-forum.com/t/unable-to-create-record-with-has-mant-through-relationship/174365)

<div class="topic-metadata">

**Author:** [@dhaval\_parikh33](https://www.ruby-forum.com/u/dhaval_parikh33)\
**Replies:** 8\
**Last updated:** [August 27, 2009, 7:46am UTC](https://www.ruby-forum.com/t/unable-to-create-record-with-has-mant-through-relationship/174365 "2009-08-27T07:46:17Z")

</div>

hi all, i have a has\_many :through r’ship in my application. my tables are - users, apps(short form for applications), categorizations. i’m trying to create a user in new.rhtml where all apps are also shown in checkbo…

---

## [Grab only the latest comment](https://www.ruby-forum.com/t/grab-only-the-latest-comment/174466)

<div class="topic-metadata">

**Author:** [@gkrdvl](https://www.ruby-forum.com/u/gkrdvl)\
**Replies:** 1\
**Last updated:** [August 27, 2009, 6:47am UTC](https://www.ruby-forum.com/t/grab-only-the-latest-comment/174466 "2009-08-27T06:47:51Z")

</div>

Hi all In a typical User - Post - Comment model in Rails, every user can create a Post and also can create Comment, question is how to grab every user latest comment on specific post. Example: Post A have 3 user mak…

---

## [Hijack for Rails](https://www.ruby-forum.com/t/hijack-for-rails/174470)

<div class="topic-metadata">

**Author:** [@msojka](https://www.ruby-forum.com/u/msojka)\
**Replies:** 0\
**Last updated:** [August 27, 2009, 4:28am UTC](https://www.ruby-forum.com/t/hijack-for-rails/174470 "2009-08-27T04:28:35Z")

</div>

I have written a short tutorial on using Hijack to debug running Ruby processes, including Rails applications. The article is available now at Stowarzyszenie Polski Recykling. Enjoy! Martin

---

## [Should be simple: Get all levels of stack trace from failed server startup](https://www.ruby-forum.com/t/should-be-simple-get-all-levels-of-stack-trace-from-failed-server-startup/174432)

<div class="topic-metadata">

**Author:** [@steve](https://www.ruby-forum.com/u/steve)\
**Replies:** 2\
**Last updated:** [August 27, 2009, 2:56am UTC](https://www.ruby-forum.com/t/should-be-simple-get-all-levels-of-stack-trace-from-failed-server-startup/174432 "2009-08-27T02:56:41Z")

</div>

Hi, I am trying to debug another problem that occurs when starting the web server (either Mongrel or Webrick). The error message it gives me is useless, because it hides “…22 levels…”. Unfortunatly, the first few l…

---

## [Help with abstracting ActiveRecord models](https://www.ruby-forum.com/t/help-with-abstracting-activerecord-models/174383)

<div class="topic-metadata">

**Author:** [@Jeff\_Larkin](https://www.ruby-forum.com/u/Jeff_Larkin)\
**Replies:** 4\
**Last updated:** [August 27, 2009, 12:33am UTC](https://www.ruby-forum.com/t/help-with-abstracting-activerecord-models/174383 "2009-08-27T00:33:52Z")

</div>

Hi all. I’m looking for suggestions of how other people have implemented a situation like the following. I’d like to create a base activerecord model, let’s call it Widget, from which other classes are based. I’d l…

---

## [Another NoMethodError](https://www.ruby-forum.com/t/another-nomethoderror/174460)

<div class="topic-metadata">

**Author:** [@bobm](https://www.ruby-forum.com/u/bobm)\
**Replies:** 2\
**Last updated:** [August 26, 2009, 11:54pm UTC](https://www.ruby-forum.com/t/another-nomethoderror/174460 "2009-08-26T23:54:03Z")

</div>

I have an ActiveRecord class called Foo that I’ve added some methods to in the foo.rb file. I have created an instance of Foo within another ActiveRecord Bar within the file bar.rb. I keep getting this error: NoMeth…

---

## [Automating online banking login & checking for new transactions - what's best approach? (e.g. which](https://www.ruby-forum.com/t/automating-online-banking-login-checking-for-new-transactions-whats-best-approach-e-g-which/197095)

<div class="topic-metadata">

**Author:** [@greg](https://www.ruby-forum.com/u/greg)\
**Replies:** 0\
**Last updated:** [August 26, 2009, 11:48pm UTC](https://www.ruby-forum.com/t/automating-online-banking-login-checking-for-new-transactions-whats-best-approach-e-g-which/197095 "2009-08-26T23:48:47Z")

</div>

Hi, I’m interested in automating online banking login & checking for new transactions - what’s best approach? (e.g. which gems/libraries etc) Anyone already built something that does this? For example login each hou…

---

## [Forcing a DB transaction to go through](https://www.ruby-forum.com/t/forcing-a-db-transaction-to-go-through/174292)

<div class="topic-metadata">

**Author:** [@trevoke](https://www.ruby-forum.com/u/trevoke)\
**Replies:** 5\
**Last updated:** [August 26, 2009, 11:27pm UTC](https://www.ruby-forum.com/t/forcing-a-db-transaction-to-go-through/174292 "2009-08-26T23:27:42Z")

</div>

This is the ‘sequel’ to this: http://www.ruby-forum.com/topic/193688 By ‘sequel’, I mean that this is actually the problem I am having. Aldric G. wrote: Okay, I finally got a clear look at the log, and it is indeed …

---

## [Strange Active::Record behavior, StatementInvalid exception thrown twice?](https://www.ruby-forum.com/t/strange-active-record-behavior-statementinvalid-exception-thrown-twice/174427)

<div class="topic-metadata">

**Author:** [@anr](https://www.ruby-forum.com/u/anr)\
**Replies:** 3\
**Last updated:** [August 26, 2009, 10:46pm UTC](https://www.ruby-forum.com/t/strange-active-record-behavior-statementinvalid-exception-thrown-twice/174427 "2009-08-26T22:46:08Z")

</div>

Hi, I’m a bit puzzled with an ActiveRecord::StatementInvalid exception that’s apparently being thrown twice. I’m using Rails 2.3.3 and Postgres, and inside the Feed Model I have something like: has\_many :entries, :d…

---

## [F.select onchange determine other fields in view](https://www.ruby-forum.com/t/f-select-onchange-determine-other-fields-in-view/174375)

<div class="topic-metadata">

**Author:** [@newtoror](https://www.ruby-forum.com/u/newtoror)\
**Replies:** 5\
**Last updated:** [August 26, 2009, 10:19pm UTC](https://www.ruby-forum.com/t/f-select-onchange-determine-other-fields-in-view/174375 "2009-08-26T22:19:47Z")

</div>

I am trying to create a view/form that has a dropdown \<%= f.label :type\_id%\> \<%= f.select :type\_id,Type.all.collect{|c| \[c.description,c.id\]}, :onchange=\>"HERE I NEED TO DO SOMETHING WHAT?" %\> Now whe…

---

## [Alphabetize pagination](https://www.ruby-forum.com/t/alphabetize-pagination/174406)

<div class="topic-metadata">

**Author:** [@p\_W](https://www.ruby-forum.com/u/p_W)\
**Replies:** 4\
**Last updated:** [August 26, 2009, 9:51pm UTC](https://www.ruby-forum.com/t/alphabetize-pagination/174406 "2009-08-26T21:51:40Z")

</div>

Note I have not tried anything about my question, nor Googled anything about it yet, I was just wondering if this was possible, so if you wanna answer with lmgtfy, rtfm, or anything like that, please get it out of th…

---

## [Swf object works on firefox and chrome but not on IE](https://www.ruby-forum.com/t/swf-object-works-on-firefox-and-chrome-but-not-on-ie/162340)

<div class="topic-metadata">

**Author:** [@shuaib85](https://www.ruby-forum.com/u/shuaib85)\
**Replies:** 2\
**Last updated:** [August 26, 2009, 9:23pm UTC](https://www.ruby-forum.com/t/swf-object-works-on-firefox-and-chrome-but-not-on-ie/162340 "2009-08-26T21:23:33Z")

</div>

Dear all As usual I face dozens of problems on IE, everythings i create works fine on both chrome and firefox but not always on IE. This time I am using swfobject to display flash banners on my site. The banner works…

---

## [Record saving problem](https://www.ruby-forum.com/t/record-saving-problem/174404)

<div class="topic-metadata">

**Author:** [@difei](https://www.ruby-forum.com/u/difei)\
**Replies:** 4\
**Last updated:** [August 26, 2009, 9:11pm UTC](https://www.ruby-forum.com/t/record-saving-problem/174404 "2009-08-26T21:11:51Z")

</div>

Greetings all, I have some active\_record models which have same columns, for instance: model A (int id, vchar name, vchar code) model B (int id, vchar name, vchar code) I can initiate a new model B object using “b =…

[Previous page](https://www.ruby-forum.com/c/ruby-on-rails/6.md?page=827)

[Next page](https://www.ruby-forum.com/c/ruby-on-rails/6.md?page=829)
