Displaying 6 results from an estimated 6 matches for "each_hash".
2006 Jan 17
15
legacy database and finder_sql nightmare!
This is my first rails app with a legacy database and I''m having a
terrible time getting the models set up correctly. I have an order
table that has a primary field named order_number. I have a name table
with a primary of item_number. These two tables are liked by the
item_number and the order_number, but not as you might think. If the
order_number is 2500, then each entry in
2006 Apr 07
0
Updating a relationship in a has_many and belongs_to
...arams["group_#{params[:id]}"].each_with_index do |id, position|
Page.update(id, :position => position + 1, :menu => menu)
end
When I run the Below it sometimes works but always says: You have a nil
object when you didn''t expect it!The error occured while evaluating
nil.each_hash
params["group_#{params[:id]}"].each_with_index do |id, position|
@page = Page.find(id)
@page.position = position + 1
@page.save!
@page = nil
Page.find_by_sql(["UPDATE pages SET menu_id = ? WHERE id =
?;",params[:id], id])
end
Basically what I need is either a way t...
2006 Jan 15
0
OS X Rails - Nuby
...rails (either running tests, or running a rails page that hits
the DB) it just hangs forever and does nothing. If I stop the browser
and refresh, I see this message:
NoMethodError in Organize#index
You have a nil object when you didn''t expect it!
The error occured while evaluating nil.each_hash
RAILS_ROOT: script/../config/..
Application Trace | Framework Trace | Full Trace
/usr/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connection_adapters/mysql_adapter.rb:325:in
`select''
/usr/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connection_adapters/m...
2006 Jan 15
2
Please help - Rails hanging on mysql connection
...and
other direct calls to the DB just hang (for example, the test says
"Starting" and then doesn''t do anything for minutes on end (simple
test).
NoMethodError in Organize#index
You have a nil object when you didn''t expect it!
The error occured while evaluating nil.each_hash
RAILS_ROOT: script/../config/..
Application Trace | Framework Trace | Full Trace
/usr/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connection_adapters/mysql_adapter.rb:325:in
`select''
/usr/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connection_adapters/my...
2009 Jan 13
9
Segmentation Fault : [i386-mswin32] in wxruby
Greetings,
I have created a GUI to generate a output text file using wxruby. my
program codes are about ~1400 lines.
ruby : 1.8.6
wxruby : 1.9.7
rails : 2.1.0
FYI, I am using the TextCtrl & combobox in the main GUI to get the
output file name and main settings. after clicking the button, it will
pop up another frame which let user to select and modified settings with
TextCtrl & combobox.
2006 Jun 04
20
Proposal of some radical changes to API
Hey guys,
Now that the Lucy[1] project has Apache approval and is about to
begin, the onus is no longer on Ferret to strive for Lucene
compatability. (We''ll be doing that in Lucy). So I''m starting to think
about ways to improve Ferret''s API. The first part that needs to be
improved is the Document API. It''s annoying having to type all the
attributes to