# Rails

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

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

---

## [Job Post - Ruby on Rails programmer UC Berkeley](https://www.ruby-forum.com/t/job-post-ruby-on-rails-programmer-uc-berkeley/178941)

<div class="topic-metadata">

**Author:** [@Magee](https://www.ruby-forum.com/u/Magee)\
**Replies:** 0\
**Last updated:** [November 13, 2009, 8:23pm UTC](https://www.ruby-forum.com/t/job-post-ruby-on-rails-programmer-uc-berkeley/178941 "2009-11-13T20:23:09Z")

</div>

The Northern California Childhood Leukemia Study of the UC Berkeley School of Public Health is hiring an Applications Programmer to help develop new research and operational systems using Ruby on Rails. Brief summary …

---

## [Learning ruby on Mac - rake create error](https://www.ruby-forum.com/t/learning-ruby-on-mac-rake-create-error/175082)

<div class="topic-metadata">

**Author:** [@kkoehler](https://www.ruby-forum.com/u/kkoehler)\
**Replies:** 4\
**Last updated:** [November 13, 2009, 8:10pm UTC](https://www.ruby-forum.com/t/learning-ruby-on-mac-rake-create-error/175082 "2009-11-13T20:10:16Z")

</div>

I can do a mysql -u root and then type in create database restaurant\_test, development, production but when I run rake db:create:all I get: (in /Users/katherinekoehler/Documents/workspace/kkoehler/classes/ruby/lesson…

---

## [Getting the last record for an each loop?](https://www.ruby-forum.com/t/getting-the-last-record-for-an-each-loop/178891)

<div class="topic-metadata">

**Author:** [@bagadoughnuts](https://www.ruby-forum.com/u/bagadoughnuts)\
**Replies:** 7\
**Last updated:** [November 13, 2009, 7:44pm UTC](https://www.ruby-forum.com/t/getting-the-last-record-for-an-each-loop/178891 "2009-11-13T19:44:23Z")

</div>

Hi all, I need a very similar functionality to what is displayed on the group\_by Month railscast (#29 group\_by Month - RailsCasts). The code is this… \<% @task\_months.sort.each do |month, tasks| %\> \<%= month.strfti…

---

## [Ticketing/bugtracking plugin for rails](https://www.ruby-forum.com/t/ticketing-bugtracking-plugin-for-rails/178930)

<div class="topic-metadata">

**Author:** [@christoph\_j](https://www.ruby-forum.com/u/christoph_j)\
**Replies:** 1\
**Last updated:** [November 13, 2009, 7:30pm UTC](https://www.ruby-forum.com/t/ticketing-bugtracking-plugin-for-rails/178930 "2009-11-13T19:30:05Z")

</div>

Hi, I’m looking for a plugin which would enable my rails application to address bugtracking/ticketing similar to lighthouse. The only dependency I can think of is a user model which I would provide. I only need simp…

---

## [Double POST using form\_remote\_tag?](https://www.ruby-forum.com/t/double-post-using-form-remote-tag/178889)

<div class="topic-metadata">

**Author:** [@mperham](https://www.ruby-forum.com/u/mperham)\
**Replies:** 4\
**Last updated:** [November 13, 2009, 6:53pm UTC](https://www.ruby-forum.com/t/double-post-using-form-remote-tag/178889 "2009-11-13T18:53:45Z")

</div>

Using form\_remote\_tag I get this generated HTML: As you can see, it has an onsubmit and an action. The onsubmit sends an Ajax request. Sometimes, on some browsers (Firefox 3.0.1 on Windows) this sends 2 HTTP POST req…

---

## [How to use link\_to for an external reference?](https://www.ruby-forum.com/t/how-to-use-link-to-for-an-external-reference/178869)

<div class="topic-metadata">

**Author:** [@explainer](https://www.ruby-forum.com/u/explainer)\
**Replies:** 2\
**Last updated:** [November 13, 2009, 6:02pm UTC](https://www.ruby-forum.com/t/how-to-use-link-to-for-an-external-reference/178869 "2009-11-13T18:02:41Z")

</div>

Suppose I wish to have the following link embedded in one of my views. Ruby on Rails How can I use the ‘link\_to’ method to generate an external link in an .erb file? I have tried various options, but keep getting ro…

---

## [RoR Pre-Sales Consultant - Toronto](https://www.ruby-forum.com/t/ror-pre-sales-consultant-toronto/178927)

<div class="topic-metadata">

**Author:** [@wiz0rd](https://www.ruby-forum.com/u/wiz0rd)\
**Replies:** 0\
**Last updated:** [November 13, 2009, 5:32pm UTC](https://www.ruby-forum.com/t/ror-pre-sales-consultant-toronto/178927 "2009-11-13T17:32:50Z")

</div>

Hello everyone, happy friday! Any Ruby on Rails Client/Software Consultants in Toronto? Looking for a full time Pre-Sales Engineer, someone who has good experience going to client sites and doing technical presentatio…

---

## [Xml : why is the Model ID field missing](https://www.ruby-forum.com/t/xml-why-is-the-model-id-field-missing/178910)

<div class="topic-metadata">

**Author:** [@bingobob](https://www.ruby-forum.com/u/bingobob)\
**Replies:** 3\
**Last updated:** [November 13, 2009, 5:26pm UTC](https://www.ruby-forum.com/t/xml-why-is-the-model-id-field-missing/178910 "2009-11-13T17:26:23Z")

</div>

Sorry if I’m missing something here but I’ve simply created a respond\_to block with an xml type in it so that user can go to www.foo.com/foos.xml and get xml back. Works fine but I need the foo\_id in there and I don’t …

---

## [Please help me ------ Mapping an item to article](https://www.ruby-forum.com/t/please-help-me-mapping-an-item-to-article/178858)

<div class="topic-metadata">

**Author:** [@Rails\_ROR](https://www.ruby-forum.com/u/Rails_ROR)\
**Replies:** 1\
**Last updated:** [November 13, 2009, 4:16pm UTC](https://www.ruby-forum.com/t/please-help-me-mapping-an-item-to-article/178858 "2009-11-13T16:16:09Z")

</div>

Hi everybody, I have a form like this New menuitem \<% form\_for(@menuitem) do |f| %\> \<%= f.error\_messages %\> \<%= f.label :title %\> \<%= f.text\_field :title %\> \<%= f.label :alias %\> \<%= f.tex…

---

## [Unsubscribe](https://www.ruby-forum.com/t/unsubscribe/178922)

<div class="topic-metadata">

**Author:** [@Oluwayomi\_O](https://www.ruby-forum.com/u/Oluwayomi_O)\
**Replies:** 0\
**Last updated:** [November 13, 2009, 3:05pm UTC](https://www.ruby-forum.com/t/unsubscribe/178922 "2009-11-13T15:05:53Z")

</div>

Hello, Kindly unsubscribe me for now.I will join at a later date because the volume of mails from the forum coming to my inbox is just too much!!! Regards and Respects, Kindness in thought leads to wisdom. Kindness …

---

## [Delegates and building associations](https://www.ruby-forum.com/t/delegates-and-building-associations/178906)

<div class="topic-metadata">

**Author:** [@twiggle](https://www.ruby-forum.com/u/twiggle)\
**Replies:** 1\
**Last updated:** [November 13, 2009, 1:05pm UTC](https://www.ruby-forum.com/t/delegates-and-building-associations/178906 "2009-11-13T13:05:17Z")

</div>

Class User \<\< ActiveRecord::Base has\_one :profile delgate :description, :description=, :to =\> :profile end I’d like to do, @user = User.create(:name =\> ‘Foo B.’, :description =\> ‘Slow.’) or @user = User.update\_at…

---

## [Question about Ruby on Rails Technology](https://www.ruby-forum.com/t/question-about-ruby-on-rails-technology/178892)

<div class="topic-metadata">

**Author:** [@hoangnguyenducbk](https://www.ruby-forum.com/u/hoangnguyenducbk)\
**Replies:** 6\
**Last updated:** [November 13, 2009, 12:58pm UTC](https://www.ruby-forum.com/t/question-about-ruby-on-rails-technology/178892 "2009-11-13T12:58:51Z")

</div>

I have one Web project with those requirements: Show 3D with animation about a house, room, department….In these houses, there are some button that we can press to control. When we click to it, it will take a command…

---

## [Wrong number of arguments (0 for 1) in callback method](https://www.ruby-forum.com/t/wrong-number-of-arguments-0-for-1-in-callback-method/178904)

<div class="topic-metadata">

**Author:** [@kalpesh13131](https://www.ruby-forum.com/u/kalpesh13131)\
**Replies:** 6\
**Last updated:** [November 13, 2009, 12:10pm UTC](https://www.ruby-forum.com/t/wrong-number-of-arguments-0-for-1-in-callback-method/178904 "2009-11-13T12:10:45Z")

</div>

I was creating this simple rail application. my controller method looks like this: def create() @simple = Simple.new(params\[:simple\]) ##params coming from view @simple.save end And my model class “Simple” as below: …

---

## [Ruport-how to send email to multiple recipients](https://www.ruby-forum.com/t/ruport-how-to-send-email-to-multiple-recipients/178897)

<div class="topic-metadata">

**Author:** [@marlon](https://www.ruby-forum.com/u/marlon)\
**Replies:** 4\
**Last updated:** [November 13, 2009, 11:49am UTC](https://www.ruby-forum.com/t/ruport-how-to-send-email-to-multiple-recipients/178897 "2009-11-13T11:49:12Z")

</div>

I have this script but currently it only send email to one recipient. Someone knows how to send email to multiple recipients? Please help. require ‘ruport’ require ‘ruport/util’ r = Ruport::Report.new r.add\_mailer …

---

## [ActiveRecord Typecast](https://www.ruby-forum.com/t/activerecord-typecast/178900)

<div class="topic-metadata">

**Author:** [@davidstokar](https://www.ruby-forum.com/u/davidstokar)\
**Replies:** 1\
**Last updated:** [November 13, 2009, 11:44am UTC](https://www.ruby-forum.com/t/activerecord-typecast/178900 "2009-11-13T11:44:31Z")

</div>

Hello, It appears that ActiveRecord is not performing any typcasting of model attributes in my rails app. So, in my app all attributes are loaded from the database as strings (e.g. integers, floats, dates, etc are al…

---

## [How to find records](https://www.ruby-forum.com/t/how-to-find-records/178899)

<div class="topic-metadata">

**Author:** [@newb](https://www.ruby-forum.com/u/newb)\
**Replies:** 3\
**Last updated:** [November 13, 2009, 11:42am UTC](https://www.ruby-forum.com/t/how-to-find-records/178899 "2009-11-13T11:42:10Z")

</div>

dear all how to find records which are 2 days older than from current date. i have a date field in my table. any exmaple pls…

---

## [Calculate rebate in a web shop](https://www.ruby-forum.com/t/calculate-rebate-in-a-web-shop/178907)

<div class="topic-metadata">

**Author:** [@paulbutcher](https://www.ruby-forum.com/u/paulbutcher)\
**Replies:** 0\
**Last updated:** [November 13, 2009, 11:14am UTC](https://www.ruby-forum.com/t/calculate-rebate-in-a-web-shop/178907 "2009-11-13T11:14:59Z")

</div>

My 2 brain cells have difficulties with this problem. I’m creating a web shop where each item has a price. If you buy 3 you get a lower price for each item and then even lower when you buy 6. Each item in the product …

---

## [Got NoMethodError on Model's find method](https://www.ruby-forum.com/t/got-nomethoderror-on-models-find-method/178848)

<div class="topic-metadata">

**Author:** [@adinda\_p](https://www.ruby-forum.com/u/adinda_p)\
**Replies:** 3\
**Last updated:** [November 13, 2009, 10:42am UTC](https://www.ruby-forum.com/t/got-nomethoderror-on-models-find-method/178848 "2009-11-13T10:42:26Z")

</div>

Hi All, I don’t know how this could happen. I got NoMethodError on running a simple Model’s find method. At first i have the same error for running find\_all\_by\_country method where country is one of the model’s attr…

---

## [DB Table Constraints using code or not! Best practices?](https://www.ruby-forum.com/t/db-table-constraints-using-code-or-not-best-practices/178840)

<div class="topic-metadata">

**Author:** [@bzouchir](https://www.ruby-forum.com/u/bzouchir)\
**Replies:** 6\
**Last updated:** [November 13, 2009, 6:56am UTC](https://www.ruby-forum.com/t/db-table-constraints-using-code-or-not-best-practices/178840 "2009-11-13T06:56:20Z")

</div>

Hi guys, although this is not Rails specific, I have built this Rails app and designed the MySQL database with all constraints and indexes using MySQL Workbench. It is a pretty tool that allows to you to quickly buil…

---

## [Errors during sqlite3 install](https://www.ruby-forum.com/t/errors-during-sqlite3-install/178853)

<div class="topic-metadata">

**Author:** [@kangaroo99](https://www.ruby-forum.com/u/kangaroo99)\
**Replies:** 3\
**Last updated:** [November 13, 2009, 6:02am UTC](https://www.ruby-forum.com/t/errors-during-sqlite3-install/178853 "2009-11-13T06:02:40Z")

</div>

I have localhost:3000 working. Windows xp system I placed sqlite3.exe and dll in windows/system directory and made sure it was in the path. When I used gem install sqlite3-ruby it gave a large number of errors in…

---

## [Advice on finding a Ruby on Rails developer and/or an outsourced company](https://www.ruby-forum.com/t/advice-on-finding-a-ruby-on-rails-developer-and-or-an-outsourced-company/178852)

<div class="topic-metadata">

**Author:** [@damien](https://www.ruby-forum.com/u/damien)\
**Replies:** 2\
**Last updated:** [November 13, 2009, 1:51am UTC](https://www.ruby-forum.com/t/advice-on-finding-a-ruby-on-rails-developer-and-or-an-outsourced-company/178852 "2009-11-13T01:51:29Z")

</div>

To all, Looking for advice on how to find a developer or outsourced company that is experienced in Ruby on Rails to take a current software program built on Access/visual basic and Crystal Reports to the web using th…

---

## [How can I inspect the test env database?](https://www.ruby-forum.com/t/how-can-i-inspect-the-test-env-database/178878)

<div class="topic-metadata">

**Author:** [@elliottg](https://www.ruby-forum.com/u/elliottg)\
**Replies:** 4\
**Last updated:** [November 13, 2009, 1:41am UTC](https://www.ruby-forum.com/t/how-can-i-inspect-the-test-env-database/178878 "2009-11-13T01:41:32Z")

</div>

I’m wanting to be able to inspect what is actually getting written to the test database when/after tests are ran. However I do no not know how to do this. Since after each test is ran the DB is wiped. How can I someho…

---

## [Rendering a result from a different controller](https://www.ruby-forum.com/t/rendering-a-result-from-a-different-controller/178855)

<div class="topic-metadata">

**Author:** [@db\_333](https://www.ruby-forum.com/u/db_333)\
**Replies:** 2\
**Last updated:** [November 13, 2009, 1:08am UTC](https://www.ruby-forum.com/t/rendering-a-result-from-a-different-controller/178855 "2009-11-13T01:08:10Z")

</div>

Hi, I am a bit new at rails, so I’m not sure how to approach this: I have a view with a search box that calls a controller/model outside of the view. So the view I am working with is called ‘groups’ and I make a se…

---

## [RJS, select, & replace\_html](https://www.ruby-forum.com/t/rjs-select-replace-html/178880)

<div class="topic-metadata">

**Author:** [@willclarkdesigns](https://www.ruby-forum.com/u/willclarkdesigns)\
**Replies:** 2\
**Last updated:** [November 12, 2009, 11:41pm UTC](https://www.ruby-forum.com/t/rjs-select-replace-html/178880 "2009-11-12T23:41:11Z")

</div>

I need to update a series of html tags with the same content. I’ve tried running the following in my rjs file: page.select(".some\_class").each do |item| item.replace\_html(“Some Content”) end But it won’t work. Howe…

---

## [Schema dump does not reflect column size limit](https://www.ruby-forum.com/t/schema-dump-does-not-reflect-column-size-limit/178787)

<div class="topic-metadata">

**Author:** [@hildegunst](https://www.ruby-forum.com/u/hildegunst)\
**Replies:** 4\
**Last updated:** [November 12, 2009, 10:51pm UTC](https://www.ruby-forum.com/t/schema-dump-does-not-reflect-column-size-limit/178787 "2009-11-12T22:51:47Z")

</div>

Hi, Everything is in the title. With Rails 2.3.4 and MySQL 5.0.41: If have a table like this: ±---------------±-----------±-----±----±--------±---------------+ | Field | Type | Null | Key…

---

## [Nested routes and a missing method](https://www.ruby-forum.com/t/nested-routes-and-a-missing-method/178875)

<div class="topic-metadata">

**Author:** [@byrnejb](https://www.ruby-forum.com/u/byrnejb)\
**Replies:** 1\
**Last updated:** [November 12, 2009, 10:40pm UTC](https://www.ruby-forum.com/t/nested-routes-and-a-missing-method/178875 "2009-11-12T22:40:40Z")

</div>

I have this nested route: map.resource :users do |user| user.resources :roles end Which, among others, gives me this named routing, user\_roles: user\_roles GET /users/:user\_id/roles (.:format) {:controller=\>“rol…

---

## [RubyGem version error: rack(0.3.0 not ~\> 1.0.0) on deploy](https://www.ruby-forum.com/t/rubygem-version-error-rack-0-3-0-not-1-0-0-on-deploy/178823)

<div class="topic-metadata">

**Author:** [@Luciano](https://www.ruby-forum.com/u/Luciano)\
**Replies:** 4\
**Last updated:** [November 12, 2009, 9:44pm UTC](https://www.ruby-forum.com/t/rubygem-version-error-rack-0-3-0-not-1-0-0-on-deploy/178823 "2009-11-12T21:44:28Z")

</div>

Hello there! I’m trying to deploy a application, but capistrano gives me the following error: \*\*\* \[err :: my-domain.com\] rake aborted! \*\*\* \[err :: my-domain.com\] RubyGem version error: rack(0.3.0 not ~\> 1.0.0) \*\*\* …

---

## [Model question](https://www.ruby-forum.com/t/model-question/178874)

<div class="topic-metadata">

**Author:** [@mark](https://www.ruby-forum.com/u/mark)\
**Replies:** 3\
**Last updated:** [November 12, 2009, 9:02pm UTC](https://www.ruby-forum.com/t/model-question/178874 "2009-11-12T21:02:16Z")

</div>

Heyya, I am working on a apartments rent model. Some apartments are individual with address, price … fields and the model for this is streightforward. Some apartments are a collection of apts in a complex with the s…

---

## [Validates\_uniquenes\_of with decimal columns and mysql](https://www.ruby-forum.com/t/validates-uniquenes-of-with-decimal-columns-and-mysql/178872)

<div class="topic-metadata">

**Author:** [@Eddy\_J](https://www.ruby-forum.com/u/Eddy_J)\
**Replies:** 0\
**Last updated:** [November 12, 2009, 7:59pm UTC](https://www.ruby-forum.com/t/validates-uniquenes-of-with-decimal-columns-and-mysql/178872 "2009-11-12T19:59:05Z")

</div>

I’m using this validation in my model: validates\_uniqueness\_of :zoom\_level, :scope =\> \[:latitude, :longitude\] :latitude and :longitude are decimal columns in a mysql database. It isn’t working. I’ve searched in Googl…

---

## [Nokogiri: parsing tags](https://www.ruby-forum.com/t/nokogiri-parsing-tags/178798)

<div class="topic-metadata">

**Author:** [@introvert](https://www.ruby-forum.com/u/introvert)\
**Replies:** 2\
**Last updated:** [November 12, 2009, 7:47pm UTC](https://www.ruby-forum.com/t/nokogiri-parsing-tags/178798 "2009-11-12T19:47:17Z")

</div>

Hello, I’m trying to use nokogiri gem to parse individual xhtml tags (not the whole html document) and preform some processing on them. Heres an example of a string that I want to process: str = ’ some texttest …’ T…

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

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