# Rails

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

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

---

## [Segmentation fault when loading fixtures](https://www.ruby-forum.com/t/segmentation-fault-when-loading-fixtures/176186)

<div class="topic-metadata">

**Author:** [@russianbandit](https://www.ruby-forum.com/u/russianbandit)\
**Replies:** 6\
**Last updated:** [September 28, 2009, 6:34pm UTC](https://www.ruby-forum.com/t/segmentation-fault-when-loading-fixtures/176186 "2009-09-28T18:34:46Z")

</div>

I created some performance fixtures that load around 100k+ items through a fixture. While the fixture is loading I get a seg fault: /ruby/lib/ruby/1.8/yaml.rb:133: \[BUG\] Segmentation fault Would anyone be able to shin…

---

## [Two tables, clickable row one table to fill other table](https://www.ruby-forum.com/t/two-tables-clickable-row-one-table-to-fill-other-table/175366)

<div class="topic-metadata">

**Author:** [@jmaenpaa](https://www.ruby-forum.com/u/jmaenpaa)\
**Replies:** 13\
**Last updated:** [September 28, 2009, 5:24pm UTC](https://www.ruby-forum.com/t/two-tables-clickable-row-one-table-to-fill-other-table/175366 "2009-09-28T17:24:15Z")

</div>

Hello all, This one has kept me up at night. I’m kind of new to Ruby on Rails (5 weeks and counting). I have two tables. One table is created by the input of a .csv file. Imports imports\_id imports\_title descripti…

---

## [Problem accessing paperclip file attributes in a callback (observer)](https://www.ruby-forum.com/t/problem-accessing-paperclip-file-attributes-in-a-callback-observer/176292)

<div class="topic-metadata">

**Author:** [@coolmenu](https://www.ruby-forum.com/u/coolmenu)\
**Replies:** 0\
**Last updated:** [September 28, 2009, 5:07pm UTC](https://www.ruby-forum.com/t/problem-accessing-paperclip-file-attributes-in-a-callback-observer/176292 "2009-09-28T17:07:20Z")

</div>

I’m having trouble accessing paperclip file attributes in an after\_destroy callback on my attachment model. I can’t seem to access the paperclip-managed attributes but I can access non-paperclip attributes. Here’s a…

---

## [Sum product of 2 fields?](https://www.ruby-forum.com/t/sum-product-of-2-fields/176283)

<div class="topic-metadata">

**Author:** [@Dudebot](https://www.ruby-forum.com/u/Dudebot)\
**Replies:** 3\
**Last updated:** [September 28, 2009, 5:05pm UTC](https://www.ruby-forum.com/t/sum-product-of-2-fields/176283 "2009-09-28T17:05:53Z")

</div>

I have a db Orders with fields qty and amount, and another linked db Person that has many Orders. I’ve been using this to sum all of the products of qty and amount: Person.find( person ).orders.inject( 0 ){ |sum, ord…

---

## [Calling a controller action from another controller](https://www.ruby-forum.com/t/calling-a-controller-action-from-another-controller/176260)

<div class="topic-metadata">

**Author:** [@jrgoodner](https://www.ruby-forum.com/u/jrgoodner)\
**Replies:** 1\
**Last updated:** [September 28, 2009, 1:00pm UTC](https://www.ruby-forum.com/t/calling-a-controller-action-from-another-controller/176260 "2009-09-28T13:00:07Z")

</div>

Hey there, I’d like to set up my application so that, upon successfully creating a new user (within the users controller), that user is automatically logged in. So this is what I figured might work, but it doesn’t: …

---

## [Testing Referential Integrity](https://www.ruby-forum.com/t/testing-referential-integrity/176255)

<div class="topic-metadata">

**Author:** [@diabolist](https://www.ruby-forum.com/u/diabolist)\
**Replies:** 3\
**Last updated:** [September 28, 2009, 12:29pm UTC](https://www.ruby-forum.com/t/testing-referential-integrity/176255 "2009-09-28T12:29:42Z")

</div>

Hey all, I am having a little trouble getting some referential integrity tests to work well. Right now, I am using Postgres as my database. I have generated migrations for my tables and ensured referential integrity…

---

## [Arrays into columns](https://www.ruby-forum.com/t/arrays-into-columns/176268)

<div class="topic-metadata">

**Author:** [@sajeev86](https://www.ruby-forum.com/u/sajeev86)\
**Replies:** 2\
**Last updated:** [September 28, 2009, 10:53am UTC](https://www.ruby-forum.com/t/arrays-into-columns/176268 "2009-09-28T10:53:50Z")

</div>

hey (first post jitters…) Im a baby in rails web development-please be obvious How would I get an array as a column set of data? Could I just generate the table with: title:string description:text … list:array Is ar…

---

## [Getting class name in plugin](https://www.ruby-forum.com/t/getting-class-name-in-plugin/176271)

<div class="topic-metadata">

**Author:** [@artchrst](https://www.ruby-forum.com/u/artchrst)\
**Replies:** 0\
**Last updated:** [September 28, 2009, 10:48am UTC](https://www.ruby-forum.com/t/getting-class-name-in-plugin/176271 "2009-09-28T10:48:49Z")

</div>

Hi Guys, I am writing a plugin that has a “has\_many” relationships via a join\_table. It is polymorphic so I need to filter the class name. How can I get the extending class’s name in the plugin in? e.g. has\_many :c…

---

## [Error with flash and form\_authenticity\_token in new rails application with scaffolding](https://www.ruby-forum.com/t/error-with-flash-and-form-authenticity-token-in-new-rails-application-with-scaffolding/176269)

<div class="topic-metadata">

**Author:** [@kashyap](https://www.ruby-forum.com/u/kashyap)\
**Replies:** 2\
**Last updated:** [September 28, 2009, 9:50am UTC](https://www.ruby-forum.com/t/error-with-flash-and-form-authenticity-token-in-new-rails-application-with-scaffolding/176269 "2009-09-28T09:50:38Z")

</div>

Hi All, I get this strange problem with newly scaffolded apps - I’d really appreciate any help in this regard. /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.4/lib/ active\_support/message\_verifier.rb:46:in blo…

---

## [Full nested models errors listing](https://www.ruby-forum.com/t/full-nested-models-errors-listing/176270)

<div class="topic-metadata">

**Author:** [@bartocc](https://www.ruby-forum.com/u/bartocc)\
**Replies:** 0\
**Last updated:** [September 28, 2009, 9:33am UTC](https://www.ruby-forum.com/t/full-nested-models-errors-listing/176270 "2009-09-28T09:33:05Z")

</div>

Hi, I am using Rails 2.3 new nested model forms. Let’s say I want to create a book, and add 2 authors to this book. Validation happens on the author name, and both the names I’ve filled in do no validate. When I use…

---

## [New Canadian Center for Architecture website powered by Rails](https://www.ruby-forum.com/t/new-canadian-center-for-architecture-website-powered-by-rails/176272)

<div class="topic-metadata">

**Author:** [@hydrozen](https://www.ruby-forum.com/u/hydrozen)\
**Replies:** 0\
**Last updated:** [September 28, 2009, 9:27am UTC](https://www.ruby-forum.com/t/new-canadian-center-for-architecture-website-powered-by-rails/176272 "2009-09-28T09:27:13Z")

</div>

The Canadian Centre for Architecture launched recently the beta version of its new website. The Canadian Centre for Architecture is an international research centre whose main concern is to defend the idea that archit…

---

## [Should I be able to dynamically load metals at runtime?](https://www.ruby-forum.com/t/should-i-be-able-to-dynamically-load-metals-at-runtime/176264)

<div class="topic-metadata">

**Author:** [@ranjeetsmith](https://www.ruby-forum.com/u/ranjeetsmith)\
**Replies:** 0\
**Last updated:** [September 28, 2009, 8:05am UTC](https://www.ruby-forum.com/t/should-i-be-able-to-dynamically-load-metals-at-runtime/176264 "2009-09-28T08:05:12Z")

</div>

My goal is to be able to poke a metal endpoint into an app from a plugin’s init.rb AND not have said metal class’ name camelized since it contains acronyms. I didn’t think this was going to be difficult at all, but my…

---

## [How to install country\_select plug-in](https://www.ruby-forum.com/t/how-to-install-country-select-plug-in/176152)

<div class="topic-metadata">

**Author:** [@thriving](https://www.ruby-forum.com/u/thriving)\
**Replies:** 2\
**Last updated:** [September 28, 2009, 5:59am UTC](https://www.ruby-forum.com/t/how-to-install-country-select-plug-in/176152 "2009-09-28T05:59:52Z")

</div>

I have downloaded plug-in from. but i don’t know how to install it… in file install.rb there is only Install hook code here puts “The list of countries provided by this plugin may offend some users. Please review i…

---

## [Uniqueness validation perplexity](https://www.ruby-forum.com/t/uniqueness-validation-perplexity/176195)

<div class="topic-metadata">

**Author:** [@Dudebot](https://www.ruby-forum.com/u/Dudebot)\
**Replies:** 12\
**Last updated:** [September 27, 2009, 11:38pm UTC](https://www.ruby-forum.com/t/uniqueness-validation-perplexity/176195 "2009-09-27T23:38:20Z")

</div>

I want to write a validate routine to check to enforce that a position must be unique in a category. (In another category, it doesn’t have to and shouldn’t need to be unique.) I write this code which works happily f…

---

## [Heroku](https://www.ruby-forum.com/t/heroku/176206)

<div class="topic-metadata">

**Author:** [@halfbyte](https://www.ruby-forum.com/u/halfbyte)\
**Replies:** 6\
**Last updated:** [September 27, 2009, 9:41pm UTC](https://www.ruby-forum.com/t/heroku/176206 "2009-09-27T21:41:51Z")

</div>

Hi, have anyone some experience with Heroku? I have an account there, but I’m unable to tell git to work with it. Can some of you help me please? Regards Jan K.

---

## [Ajax vs. Page Refresh](https://www.ruby-forum.com/t/ajax-vs-page-refresh/176182)

<div class="topic-metadata">

**Author:** [@nozavroni](https://www.ruby-forum.com/u/nozavroni)\
**Replies:** 1\
**Last updated:** [September 27, 2009, 7:37pm UTC](https://www.ruby-forum.com/t/ajax-vs-page-refresh/176182 "2009-09-27T19:37:10Z")

</div>

More of an opinion / discussion piece. When passing a lot of data, either via ajax, or simply refreshing the page and getting a lot of data back, is it better from a “amount of work placed on the server” perspective t…

---

## [Newbie Trouble with RubyOnRails Bible](https://www.ruby-forum.com/t/newbie-trouble-with-rubyonrails-bible/176232)

<div class="topic-metadata">

**Author:** [@Arthur\_Fuller](https://www.ruby-forum.com/u/Arthur_Fuller)\
**Replies:** 3\
**Last updated:** [September 27, 2009, 7:17pm UTC](https://www.ruby-forum.com/t/newbie-trouble-with-rubyonrails-bible/176232 "2009-09-27T19:17:16Z")

</div>

Hello all, I am new to RoR and am working my way through Timothy Fisher’s Ruby On Rails Bible. I’m stuck on page 81. I have followed the steps leading to this page, i.e. cd rails\_projects rails contactlist ruby…

---

## [Auto\_complete plugin trouble](https://www.ruby-forum.com/t/auto-complete-plugin-trouble/175666)

<div class="topic-metadata">

**Author:** [@andrei](https://www.ruby-forum.com/u/andrei)\
**Replies:** 4\
**Last updated:** [September 27, 2009, 4:56pm UTC](https://www.ruby-forum.com/t/auto-complete-plugin-trouble/175666 "2009-09-27T16:56:50Z")

</div>

Hi, I want to use auto completion (following screencast #102 Auto-Complete Association - RailsCasts), but something is not working. In Aptana RadRails I have installed auto\_complete plugin. But then when I access lis…

---

## [Cost model for a RoR where users could upload lots of file? what approach?](https://www.ruby-forum.com/t/cost-model-for-a-ror-where-users-could-upload-lots-of-file-what-approach/176175)

<div class="topic-metadata">

**Author:** [@greg](https://www.ruby-forum.com/u/greg)\
**Replies:** 4\
**Last updated:** [September 27, 2009, 4:49pm UTC](https://www.ruby-forum.com/t/cost-model-for-a-ror-where-users-could-upload-lots-of-file-what-approach/176175 "2009-09-27T16:49:09Z")

</div>

Hi, Any ideas/suggestions re what a good cost model / approach would be if one’s Ruby on Rails application was to be successful, but noting users (as part of the service/application) could upload lots of files (image…

---

## [Does \<\< create a new record?](https://www.ruby-forum.com/t/does-create-a-new-record/176214)

<div class="topic-metadata">

**Author:** [@fipa](https://www.ruby-forum.com/u/fipa)\
**Replies:** 3\
**Last updated:** [September 27, 2009, 4:28pm UTC](https://www.ruby-forum.com/t/does-create-a-new-record/176214 "2009-09-27T16:28:41Z")

</div>

Search engine don’t index \<\< so it’s hard to find info about it. Let’s say I have: order = order.create item = Item.new Will order.items \<\< item create a new entry for the item in DB or not? I’m having issues.

---

## [Cross Model Validation](https://www.ruby-forum.com/t/cross-model-validation/176213)

<div class="topic-metadata">

**Author:** [@nbnbnb](https://www.ruby-forum.com/u/nbnbnb)\
**Replies:** 1\
**Last updated:** [September 27, 2009, 3:55pm UTC](https://www.ruby-forum.com/t/cross-model-validation/176213 "2009-09-27T15:55:19Z")

</div>

So I have this question: Suppose I have these 3 models: class Company \< ActiveRecord::Base has\_many :departments has\_many :employees end class Department \< ActiveRecord::Base has\_many :employees belongs\_to :compa…

---

## [Directing command output to a view](https://www.ruby-forum.com/t/directing-command-output-to-a-view/176228)

<div class="topic-metadata">

**Author:** [@petrjanda](https://www.ruby-forum.com/u/petrjanda)\
**Replies:** 0\
**Last updated:** [September 27, 2009, 1:15pm UTC](https://www.ruby-forum.com/t/directing-command-output-to-a-view/176228 "2009-09-27T13:15:10Z")

</div>

Hi all, Ive recently designed a system that is started from the command line. ie. /usr/local/bin/system.rb The system is a long running task that outputs messages via “puts” to the shell as its being executed. I ne…

---

## [Count dupliate element](https://www.ruby-forum.com/t/count-dupliate-element/176229)

<div class="topic-metadata">

**Author:** [@wangshuyi54](https://www.ruby-forum.com/u/wangshuyi54)\
**Replies:** 0\
**Last updated:** [September 27, 2009, 11:48am UTC](https://www.ruby-forum.com/t/count-dupliate-element/176229 "2009-09-27T11:48:19Z")

</div>

Tables: booking: show\_id (belongs\_to: show) show: name, venue\_id (has\_many :bookings belongs\_to :venue) venue: location, capacity ( has\_many : shows) NOW, I use this view, Listing venue rank \<% @bookings.ea…

---

## [What are methods ending in =?](https://www.ruby-forum.com/t/what-are-methods-ending-in/176219)

<div class="topic-metadata">

**Author:** [@snow-templar](https://www.ruby-forum.com/u/snow-templar)\
**Replies:** 6\
**Last updated:** [September 27, 2009, 8:22am UTC](https://www.ruby-forum.com/t/what-are-methods-ending-in/176219 "2009-09-27T08:22:12Z")

</div>

Hi, I was wondering what methods ending in an equal sign meant, but am not sure what to search for? Could anyone point me to any resources or tell me some terms to search for. Thanks! -Greg

---

## [SSL/HTTP with regards to Mongrel](https://www.ruby-forum.com/t/ssl-http-with-regards-to-mongrel/176212)

<div class="topic-metadata">

**Author:** [@tom-mac](https://www.ruby-forum.com/u/tom-mac)\
**Replies:** 1\
**Last updated:** [September 27, 2009, 3:47am UTC](https://www.ruby-forum.com/t/ssl-http-with-regards-to-mongrel/176212 "2009-09-27T03:47:14Z")

</div>

I have been looking all over and either I can’t find anything or I can’t find anything that works… so here I am. How can I go about setting up SSL/HTTP with regards to Mongrel? Thanks in advance!

---

## [Config XLSUITE in Windows](https://www.ruby-forum.com/t/config-xlsuite-in-windows/176200)

<div class="topic-metadata">

**Author:** [@rajeskannan](https://www.ruby-forum.com/u/rajeskannan)\
**Replies:** 2\
**Last updated:** [September 27, 2009, 12:11am UTC](https://www.ruby-forum.com/t/config-xlsuite-in-windows/176200 "2009-09-27T00:11:50Z")

</div>

I try to config XLSUITE in my system. I’m facing some problem i resolved it one by one. now im facing this error =\> Booting Mongrel (use ‘script/server webrick’ to force WEBrick) =\> Rails 2.2.0 application starting o…

---

## [Cleaning up test files for Paperclipped models](https://www.ruby-forum.com/t/cleaning-up-test-files-for-paperclipped-models/176218)

<div class="topic-metadata">

**Author:** [@fipa](https://www.ruby-forum.com/u/fipa)\
**Replies:** 0\
**Last updated:** [September 26, 2009, 11:52pm UTC](https://www.ruby-forum.com/t/cleaning-up-test-files-for-paperclipped-models/176218 "2009-09-26T23:52:49Z")

</div>

In my tests that use Paperclip some require that a file is provided, the problem is that in the test, when the object gets saved to DB, the associated file gets saved to disk and clutters my folders. So what’s the sol…

---

## [Running Unit Tests With SphinxSE](https://www.ruby-forum.com/t/running-unit-tests-with-sphinxse/176217)

<div class="topic-metadata">

**Author:** [@MaggotChild](https://www.ruby-forum.com/u/MaggotChild)\
**Replies:** 0\
**Last updated:** [September 26, 2009, 11:32pm UTC](https://www.ruby-forum.com/t/running-unit-tests-with-sphinxse/176217 "2009-09-26T23:32:37Z")

</div>

Several of my unit tests run queries against SphinxSE. Since Rails creates the test DB by dumping the dev DB schema, my SphinxSE queries aren’t run against the test DB. There seems to be no way to hook into the test:c…

---

## [To protect or not email attribute of user](https://www.ruby-forum.com/t/to-protect-or-not-email-attribute-of-user/176215)

<div class="topic-metadata">

**Author:** [@fipa](https://www.ruby-forum.com/u/fipa)\
**Replies:** 0\
**Last updated:** [September 26, 2009, 9:01pm UTC](https://www.ruby-forum.com/t/to-protect-or-not-email-attribute-of-user/176215 "2009-09-26T21:01:14Z")

</div>

Hi, What’s your best practice about the email attribute of a registered user in your DB. I don’t want people to be able to change email. But what’s best? protect the email attribute with attr\_protected or attr\_acce…

---

## [How to pass value to method in controller](https://www.ruby-forum.com/t/how-to-pass-value-to-method-in-controller/176208)

<div class="topic-metadata">

**Author:** [@aashishkiran](https://www.ruby-forum.com/u/aashishkiran)\
**Replies:** 3\
**Last updated:** [September 26, 2009, 5:19pm UTC](https://www.ruby-forum.com/t/how-to-pass-value-to-method-in-controller/176208 "2009-09-26T17:19:12Z")

</div>

how to pass value to method in controller using button\_to\_remote button\_to\_remote ‘check avaliability’, :url =\> { :action =\> ‘check\_for\_unique\_login’, :login =\> @user.login} above code is not working.

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

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