# Rails

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

[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:** 1645

---

## [Begin/rescue not working?](https://www.ruby-forum.com/t/begin-rescue-not-working/118832)

<div class="topic-metadata">

**Author:** [@jfoxny](https://www.ruby-forum.com/u/jfoxny)\
**Replies:** 8\
**Last updated:** [October 31, 2007, 3:58pm UTC](https://www.ruby-forum.com/t/begin-rescue-not-working/118832 "2007-10-31T15:58:03Z")

</div>

Can someone help me with the following code? I’m purposely typing in a bogus rga number, and the begin/rescue block should catch that and inform the user, right? But when I run this with a bogus number, I get the “Re…

---

## [Making this restfull](https://www.ruby-forum.com/t/making-this-restfull/118845)

<div class="topic-metadata">

**Author:** [@remcoh](https://www.ruby-forum.com/u/remcoh)\
**Replies:** 0\
**Last updated:** [October 31, 2007, 3:54pm UTC](https://www.ruby-forum.com/t/making-this-restfull/118845 "2007-10-31T15:54:19Z")

</div>

Hi, i am having great difficulties making my app restfull. this is the case: i have organisations and organisationtypes all organisations belong to a certain type. the organisationtypes are not pre-determined, so mak…

---

## [Large amount of records brings error](https://www.ruby-forum.com/t/large-amount-of-records-brings-error/118823)

<div class="topic-metadata">

**Author:** [@vapor](https://www.ruby-forum.com/u/vapor)\
**Replies:** 7\
**Last updated:** [October 31, 2007, 3:52pm UTC](https://www.ruby-forum.com/t/large-amount-of-records-brings-error/118823 "2007-10-31T15:52:06Z")

</div>

I have a page where about 500 records are displayed, or should be displayed but I have observed that when I limit records around 50 only, servers start getting hiccups and showing message that ‘Something went wrong’ a…

---

## [Include a class file for access to an object](https://www.ruby-forum.com/t/include-a-class-file-for-access-to-an-object/118762)

<div class="topic-metadata">

**Author:** [@newrubyuser](https://www.ruby-forum.com/u/newrubyuser)\
**Replies:** 1\
**Last updated:** [October 31, 2007, 3:47pm UTC](https://www.ruby-forum.com/t/include-a-class-file-for-access-to-an-object/118762 "2007-10-31T15:47:12Z")

</div>

hello all Im new to ruby and im just trying to see how i can instanciate an object that is defined in a class file like myclass.rb then in another file like start.rb i just call it like so newObj = myclass.new do i ne…

---

## [Already existing "local google search" project using Rails and Ferret?](https://www.ruby-forum.com/t/already-existing-local-google-search-project-using-rails-and-ferret/118841)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 0\
**Last updated:** [October 31, 2007, 3:28pm UTC](https://www.ruby-forum.com/t/already-existing-local-google-search-project-using-rails-and-ferret/118841 "2007-10-31T15:28:41Z")

</div>

Hi everybody! I’d like to setup a “local google search” at work: users would put data in shared directories on a samba server, without really caring about folder structure ferret would index those directories every n…

---

## ["\`require': no such file to load" while running script/console](https://www.ruby-forum.com/t/require-no-such-file-to-load-while-running-script-console/118784)

<div class="topic-metadata">

**Author:** [@Onno\_van\_der\_Straat](https://www.ruby-forum.com/u/Onno_van_der_Straat)\
**Replies:** 2\
**Last updated:** [October 31, 2007, 3:00pm UTC](https://www.ruby-forum.com/t/require-no-such-file-to-load-while-running-script-console/118784 "2007-10-31T15:00:35Z")

</div>

Hi, I setting up a new server on Linux server running SuSE Linux Entreprise Server 10. While trying to run script/console I get an error that I don’t understand. Any pointers to fix this will be greatly appreciated …

---

## [How to convert file size in KB/GB](https://www.ruby-forum.com/t/how-to-convert-file-size-in-kb-gb/118813)

<div class="topic-metadata">

**Author:** [@vidyagayathri](https://www.ruby-forum.com/u/vidyagayathri)\
**Replies:** 4\
**Last updated:** [October 31, 2007, 2:58pm UTC](https://www.ruby-forum.com/t/how-to-convert-file-size-in-kb-gb/118813 "2007-10-31T14:58:49Z")

</div>

Hi all, I want to find the file size, so i used file\_name.size, but while displaying i want to show in KB or MB like this i want to show to show the user, i tried number\_to\_human\_size helper also, but this is also no…

---

## [Has\_one and create](https://www.ruby-forum.com/t/has-one-and-create/118799)

<div class="topic-metadata">

**Author:** [@nigel.bris](https://www.ruby-forum.com/u/nigel.bris)\
**Replies:** 1\
**Last updated:** [October 31, 2007, 2:51pm UTC](https://www.ruby-forum.com/t/has-one-and-create/118799 "2007-10-31T14:51:46Z")

</div>

Hi, I am wondering why this does not work? Email.find(1).the\_file.create Email model has\_one :the\_file Email.find(1).the\_file always returns nil (until there is an association) and you cannot do a create… Any sugge…

---

## [Dates in Gettext](https://www.ruby-forum.com/t/dates-in-gettext/118825)

<div class="topic-metadata">

**Author:** [@samlown](https://www.ruby-forum.com/u/samlown)\
**Replies:** 2\
**Last updated:** [October 31, 2007, 2:41pm UTC](https://www.ruby-forum.com/t/dates-in-gettext/118825 "2007-10-31T14:41:19Z")

</div>

Hi All, It comes up quite a lot, and after much searching, I’ve not been able to find a solution to handling dates in Gettext that I actually liked. Overriding array constants inside various libraries and expecting th…

---

## [How to use singularize method](https://www.ruby-forum.com/t/how-to-use-singularize-method/117931)

<div class="topic-metadata">

**Author:** [@advait](https://www.ruby-forum.com/u/advait)\
**Replies:** 4\
**Last updated:** [October 31, 2007, 2:21pm UTC](https://www.ruby-forum.com/t/how-to-use-singularize-method/117931 "2007-10-31T14:21:48Z")

</div>

Hello I need to know how to make use of singularize method with params\[:path\], the code is something like this \<%= params\[:path\] %\> , the output of this particular statement is computers and I need to get computer. …

---

## [Database design - Bussiness/Contacts/Categories etc](https://www.ruby-forum.com/t/database-design-bussiness-contacts-categories-etc/118747)

<div class="topic-metadata">

**Author:** [@josef](https://www.ruby-forum.com/u/josef)\
**Replies:** 2\
**Last updated:** [October 31, 2007, 1:49pm UTC](https://www.ruby-forum.com/t/database-design-bussiness-contacts-categories-etc/118747 "2007-10-31T13:49:35Z")

</div>

Hi, I am just about to embark on my first rails project. I am going to be using Aptana IDE and MySQL and SVN to manage my code. I have been thinking about how to structure my database and would like some pointers. T…

---

## [Dating or Match Making site in Rails?](https://www.ruby-forum.com/t/dating-or-match-making-site-in-rails/118220)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 3\
**Last updated:** [October 31, 2007, 1:43pm UTC](https://www.ruby-forum.com/t/dating-or-match-making-site-in-rails/118220 "2007-10-31T13:43:41Z")

</div>

Has anyone developed an dating and match-making site in Rails? Open source, or somebody willing to license for a reasonable fee? Thanks! T

---

## [Starting Rails apps on server's reboot](https://www.ruby-forum.com/t/starting-rails-apps-on-servers-reboot/118806)

<div class="topic-metadata">

**Author:** [@mhfs](https://www.ruby-forum.com/u/mhfs)\
**Replies:** 5\
**Last updated:** [October 31, 2007, 1:21pm UTC](https://www.ruby-forum.com/t/starting-rails-apps-on-servers-reboot/118806 "2007-10-31T13:21:25Z")

</div>

Hello list, I’ve got a server with several Rails application running under mongrel. It works fine, but the problem is when I reboot it. Having to go to each app’s dir and restart mongrel is a pain, so I would like t…

---

## [Hash#to\_a method not performing](https://www.ruby-forum.com/t/hash-to-a-method-not-performing/118824)

<div class="topic-metadata">

**Author:** [@peter](https://www.ruby-forum.com/u/peter)\
**Replies:** 1\
**Last updated:** [October 31, 2007, 1:19pm UTC](https://www.ruby-forum.com/t/hash-to-a-method-not-performing/118824 "2007-10-31T13:19:39Z")

</div>

Hi I need to turn a hash into an array. The method .to\_a should do it. unfortunately not ha = { “c” =\> 300, “a” =\> 100, “d” =\> 400, “c” =\> 300 } logger.info('hash ’ + ha.inspect) ha.to\_a logger.info('array ’ + ha.…

---

## [Filecolumn and changing the root path](https://www.ruby-forum.com/t/filecolumn-and-changing-the-root-path/118827)

<div class="topic-metadata">

**Author:** [@Alexander\_Bierbraue](https://www.ruby-forum.com/u/Alexander_Bierbraue)\
**Replies:** 0\
**Last updated:** [October 31, 2007, 1:16pm UTC](https://www.ruby-forum.com/t/filecolumn-and-changing-the-root-path/118827 "2007-10-31T13:16:44Z")

</div>

Hi there, I just deployed my application for the first time and run into n problem with file\_column. Everytime I deploy my app all images are getting deleted. Well. OK, so I created a directory called uploads APP/sh…

---

## [Monit mongrel limit](https://www.ruby-forum.com/t/monit-mongrel-limit/118761)

<div class="topic-metadata">

**Author:** [@jnunemaker](https://www.ruby-forum.com/u/jnunemaker)\
**Replies:** 6\
**Last updated:** [October 31, 2007, 1:12pm UTC](https://www.ruby-forum.com/t/monit-mongrel-limit/118761 "2007-10-31T13:12:38Z")

</div>

What do other people use as their memory limit for mongrel in monit? I’m using these settings below and it seems like I’m getting a lot of emails and restarts. Should I bumb up the totalmem limit to 80 or 100? if …

---

## [ActiveRecord with models pointing to different databases](https://www.ruby-forum.com/t/activerecord-with-models-pointing-to-different-databases/118826)

<div class="topic-metadata">

**Author:** [@matt](https://www.ruby-forum.com/u/matt)\
**Replies:** 0\
**Last updated:** [October 31, 2007, 12:54pm UTC](https://www.ruby-forum.com/t/activerecord-with-models-pointing-to-different-databases/118826 "2007-10-31T12:54:07Z")

</div>

Good morning, My app has three basic models. They’re listed below along with their associations Project (Postgres) - Has many notes Note (Postgres) - Belongs to project, user User (Oracle) - Has many notes Each not…

---

## [Ruby-Gettext and date/time?](https://www.ruby-forum.com/t/ruby-gettext-and-date-time/79656)

<div class="topic-metadata">

**Author:** [@chrisjo](https://www.ruby-forum.com/u/chrisjo)\
**Replies:** 1\
**Last updated:** [October 31, 2007, 12:34pm UTC](https://www.ruby-forum.com/t/ruby-gettext-and-date-time/79656 "2007-10-31T12:34:18Z")

</div>

How can I have localized dates and times using Ruby-Gettext?

---

## [Ajax updating form](https://www.ruby-forum.com/t/ajax-updating-form/118822)

<div class="topic-metadata">

**Author:** [@chrisfinne](https://www.ruby-forum.com/u/chrisfinne)\
**Replies:** 0\
**Last updated:** [October 31, 2007, 12:04pm UTC](https://www.ruby-forum.com/t/ajax-updating-form/118822 "2007-10-31T12:04:10Z")

</div>

can anyone help or point me in the right direction?: I have a number of asset\_types. When I create a new asset (which belongs\_to an asset\_type), I want the form to be specific to an asset\_type (e.g. labels on the form…

---

## [Problems with :through and scaffolding](https://www.ruby-forum.com/t/problems-with-through-and-scaffolding/118821)

<div class="topic-metadata">

**Author:** [@kabish](https://www.ruby-forum.com/u/kabish)\
**Replies:** 0\
**Last updated:** [October 31, 2007, 11:43am UTC](https://www.ruby-forum.com/t/problems-with-through-and-scaffolding/118821 "2007-10-31T11:43:08Z")

</div>

Hi all, I have been experimenting a strange behaviour in a has\_many :through relationship when trying to use plugins like Active Scaffold and Streamlined. They both show correctly the records of the relationship but …

---

## [Rails booth at the MySQL Conference & Expo 2008](https://www.ruby-forum.com/t/rails-booth-at-the-mysql-conference-expo-2008/118816)

<div class="topic-metadata">

**Author:** [@Colin\_Charles](https://www.ruby-forum.com/u/Colin_Charles)\
**Replies:** 0\
**Last updated:** [October 31, 2007, 10:37am UTC](https://www.ruby-forum.com/t/rails-booth-at-the-mysql-conference-expo-2008/118816 "2007-10-31T10:37:01Z")

</div>

Hi! Are you into Rails? Can you demo some really cool, rad, Rails based application? Local to Santa Clara/Silicon Valley/San Francisco? Fancy being at a booth at the MySQL Conference & Expo 2008, from April 14-17 200…

---

## [Job Opportunities](https://www.ruby-forum.com/t/job-opportunities/118169)

<div class="topic-metadata">

**Author:** [@softwareguy999](https://www.ruby-forum.com/u/softwareguy999)\
**Replies:** 1\
**Last updated:** [October 31, 2007, 10:18am UTC](https://www.ruby-forum.com/t/job-opportunities/118169 "2007-10-31T10:18:54Z")

</div>

We’re a fully funded startup, been in business over a year and have a rapidly expanding customer base. In other words, we’re a startup as in ‘new’, not startup as in ‘risk your mortgage and come and work for next to n…

---

## [Foreign key in has\_one instead of belongs\_to](https://www.ruby-forum.com/t/foreign-key-in-has-one-instead-of-belongs-to/118803)

<div class="topic-metadata">

**Author:** [@Henrique](https://www.ruby-forum.com/u/Henrique)\
**Replies:** 1\
**Last updated:** [October 31, 2007, 6:14am UTC](https://www.ruby-forum.com/t/foreign-key-in-has-one-instead-of-belongs-to/118803 "2007-10-31T06:14:19Z")

</div>

Hi all, Is it possible to have the foreign key in the table where its model have has\_one instead of belongs\_to? Let me explain. I have a lot of tables that use the table Addresses, like Customer, Billing, etc, but I …

---

## [ROR application](https://www.ruby-forum.com/t/ror-application/118807)

<div class="topic-metadata">

**Author:** [@fruitcee](https://www.ruby-forum.com/u/fruitcee)\
**Replies:** 2\
**Last updated:** [October 31, 2007, 5:05am UTC](https://www.ruby-forum.com/t/ror-application/118807 "2007-10-31T05:05:08Z")

</div>

could anyone help me how to run my rails application?.. i have read and done so many of the online tutorials available and yet it confuses me since im using ubuntu and most of the guides are for windows… pls do help m…

---

## [ROR and Thickbox](https://www.ruby-forum.com/t/ror-and-thickbox/118801)

<div class="topic-metadata">

**Author:** [@Alexander\_Bierbraue](https://www.ruby-forum.com/u/Alexander_Bierbraue)\
**Replies:** 0\
**Last updated:** [October 31, 2007, 1:48am UTC](https://www.ruby-forum.com/t/ror-and-thickbox/118801 "2007-10-31T01:48:15Z")

</div>

Hi there, I’m trying at present to get thickbox (and jqeury) work with ROR. Well… the first step I made was adding the javascripts of thickbox and jqeury to my controller: Then I added the following line to jqeur…

---

## [Shutting of console output of params in development mode](https://www.ruby-forum.com/t/shutting-of-console-output-of-params-in-development-mode/118794)

<div class="topic-metadata">

**Author:** [@ktheory](https://www.ruby-forum.com/u/ktheory)\
**Replies:** 3\
**Last updated:** [October 31, 2007, 1:14am UTC](https://www.ruby-forum.com/t/shutting-of-console-output-of-params-in-development-mode/118794 "2007-10-31T01:14:22Z")

</div>

Is there a way to stop rails from showing what is in the “params” hash when calling a controller action in development mode? Thanks

---

## [Patch to allow "rake notes" to find "# - FIXME ..." in addition to "# FIXME ..." (for rdoc niceness)](https://www.ruby-forum.com/t/patch-to-allow-rake-notes-to-find-fixme-in-addition-to-fixme-for-rdoc-niceness/118796)

<div class="topic-metadata">

**Author:** [@phallstrom](https://www.ruby-forum.com/u/phallstrom)\
**Replies:** 0\
**Last updated:** [October 31, 2007, 1:12am UTC](https://www.ruby-forum.com/t/patch-to-allow-rake-notes-to-find-fixme-in-addition-to-fixme-for-rdoc-niceness/118796 "2007-10-31T01:12:02Z")

</div>

Howdy everyone - They say they want votes of confidence (or excitement or something :slight\_smile: for patches these days. So I’ve got one… not super exciting, but there it is… http://dev.rubyonrails.org/ticket/100…

---

## [Find :select sort on calculated value](https://www.ruby-forum.com/t/find-select-sort-on-calculated-value/118792)

<div class="topic-metadata">

**Author:** [@kadoudal](https://www.ruby-forum.com/u/kadoudal)\
**Replies:** 1\
**Last updated:** [October 31, 2007, 12:57am UTC](https://www.ruby-forum.com/t/find-select-sort-on-calculated-value/118792 "2007-10-31T00:57:23Z")

</div>

I have a table ‘posts’ , each record has 2 fields ‘post\_count’ and ‘post\_value’ I would like to find all records, sorted on the calculated ratio value: ‘post\_value’ / ‘post\_count’ I am using MySQL 5 so I could use a …

---

## [BigDecimal problem](https://www.ruby-forum.com/t/bigdecimal-problem/118695)

<div class="topic-metadata">

**Author:** [@dmitryame](https://www.ruby-forum.com/u/dmitryame)\
**Replies:** 3\
**Last updated:** [October 31, 2007, 12:00am UTC](https://www.ruby-forum.com/t/bigdecimal-problem/118695 "2007-10-31T00:00:43Z")

</div>

BigDecimal still does not behave 100% correctly, My relevant model fragment looks like this: t.column :lat, :decimal, :precision =\> 20, :scale =\> 15, :null =\> false t.column :lng, :decimal, :precision =\> 20, :scale…

---

## [Building a hash from query results](https://www.ruby-forum.com/t/building-a-hash-from-query-results/118429)

<div class="topic-metadata">

**Author:** [@jcernelli](https://www.ruby-forum.com/u/jcernelli)\
**Replies:** 2\
**Last updated:** [October 30, 2007, 11:44pm UTC](https://www.ruby-forum.com/t/building-a-hash-from-query-results/118429 "2007-10-30T23:44:20Z")

</div>

I need to build a hash out of the results of a query. I had something like this in mind: questions = survey\_questions.find( params\[:yaddayadda\]) myHash = hash.new for questions.each do |question| foo = question.some…

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

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