Displaying 20 results from an estimated 110 matches similar to: "Issues with has_many, belongs_to and dependency settings"
2006 Apr 13
4
Apache/fastcgi setup can''t find custom config/*.yml file!
All,
Apache 2/FastCGI on Linux
My fastcgi config. file is set up to run the "test" RAILS_ENV.
When I go to access a view associated with a particular controller, I
keep getting a ENOENT (file not found) error on a custom config. file
that I am attempting to load.
What I can''t figure out is why it can''t find the file.
Here''s the code that loads it in my
2005 Dec 20
0
Problem destroying in unit tests with HABTM
Hi converted two of my models to HABTM today but I am having a real
hard time getting my unit tests to pass now. Specifically, when I
destroy a record I get this error:
...many many lines of this above...
(eval):4:in `destroy_without_habtm_shim_for_categories''
(eval):4:in `destroy_without_habtm_shim_for_categories''
(eval):4:in
2007 Feb 02
0
Error: uninitialized constant LockError
Hey Guys. So, I get this error every so often, and in sneaking at the code,
it seems that it could be an easy fix, where it''s looking for a LockError,
but I think it''s a LockException.
I''m on 0.10.13 with a very large index (about a million docs) that''s staged
on several servers, which are updated daily. (Using rails 1.1.6)
Thanks for all the hard work.
2006 Aug 08
2
"include DRbUndumped" error
Hi,
I am getting my hands on trying the cool BackgrounDrb plugin.
Following various discussions and suggestsion, I included "include DRbUndumped"
in my ActiveRecord model. However, the following exception occurs
after I tried this and hit the page that uses this model. Does anyone
know why this is so? Is it possible that an object cannot be
DRbUndumped (that would mean, we
2007 Oct 01
10
Error with Mongrel_cluster
Hi Guys,
I?m getting this error with mongrel_cluster. I am able to start mongrel
through mongrel_rails start but the cluster is not working. Initially
mongrel_rails wouldn?t work but after I added $ORACLE_HOME and
$PD_LIBRARY_PATH variables it worked but mongrel_cluster isn?t working
still. The mongrel log file looks like below.
Any help is appreciated.
Thanks.
-----------begin
2005 May 19
0
Re: Problem with Rails and OCI8
Here''s a solution to the OCI8 problem shown below (change /usr/local/oracle
to your site''s oracle):
If this happens when you are running scripts at the shell prompt:
export LD_LIBRARY_PATH=/usr/local/oracle/lib
If this happens in your apache error_log, add to httpd.conf:
SetEnv LD_LIBRARY_PATH /usr/local/oracle/lib
Kevin Kleinfelter
If it''s not documented,
2007 Aug 09
1
Need Help: Installing/Using xtable package
Hi all,
Let me know if I need to ask this question of the bioconductor group.
I used the bioconductor utility to install this package and also the
CRAN package.install function.
My computer crashed a week ago. Today I reinstalled all my
bioconductor/R packages. One of my scripts is giving me the following
error:
in my script I set:
library("xtable")
print.xtable(....
and receive this
2006 May 27
2
NameError / active_support/dependencies
hi everyone
in my dev machine, everything works flawlessly
now when i uploaded my website on the server, it cannot acces User model
anymore. all other pages work by the way.
when i try to access User on console or by web, it shows:
NameError in UsersController#signup
uninitialized constant User
/usr/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:100:in
2006 Feb 10
5
Re: Manually running dispatch.fcgi fails (Please help!!)
I''m really lost on this issue. Do I need to reinstall rails / gems?
The rest of my rails setup seems to be working. I just can''t run
dispatch.fcgi. (Details in original message below).
I have no idea how to troubleshoot this. I''m not even positive it is
supposed to be runnable from the command line. I found a
troubleshooting guide that implied it was supposed to
2014 Apr 22
1
Yum cannot download from local repository
I have set up a local filesystem repo thus:
# cat /etc/yum.repos.d/LocalFiles.repo
# LocalFiles.repo
#
# This repo is used with rpms contained in a local filesystem repo
# created with createrepo. You can use this repo and yum to install
# items directly off the local disk.
#
# To use this repo with the other repos:
# yum --enablerepo=localfiles yum --nogpgcheck <yum command>
#
# or to
2006 Nov 04
0
ActiveRecord, insert and not auto-incremented primary keys...
Hi,
After playing while with ActiveRecord, I''m surprised it isn''t easier to insert data into a table whose primary key is not auto-incremented by the database server.
The following code...
---------------------------------------
-- MySQL database "test"
---------------------------------------
CREATE TABLE gardens
(
code integer NOT NULL,
name
2006 Jul 28
2
Problems connecting to remote mysql db
Hi,
I am having a problem connecting to a remote mysql db and I can''t
figure out what the problem is. When I try to connect I get the error:
getaddrinfo: no address associated with hostname.
I have looked all over for clues as to what that means but I haven''t
been able to find anything that helps. I have no problems connecting
to the database with php and with the mysql query
2006 Jul 20
1
file_column - assigning with an actual file rather than a multipart
Hi there,
I''m using the wonderful file_column and have struck an issue that
someone might have seen before.
My images already sit on the server. So, instead of passing a
multipart message I''m sending a file object.
Something like...
f = File.new("public/gallery_images/builder.png")
p = Product.find_first
p.image = f
p.save
On the save I recieve an error which
2006 Aug 08
2
Problem with plurals, migrations?
Hi,
Ruby 1.8.4
Rails 1.1.4
Windows XP Pro
I''m hitting an issue with migrations that I suspect relates to
pluralization. Here''s the migration:
class Hardware < ActiveRecord::Migration
def self.up
create_table :hardware do |h|
h.column :vendor, :string, :limit => 32
h.column :model, :string, :limit => 32
end
2006 Jul 31
2
ambiguous column name in has_many :through
In my application model I have three classes: Accounts, Projects, and Items
class Accounts < ActiveRecord::Base
has_many :items, :through => :projects, :source => :items
has_many :late_items, :class_name => ''Item'', :through => :projects,
:conditions => [''due_on < ?'', Time.now], :source => :items
end
class Projects <
2006 Jul 09
2
Error using sqlite3
Hello, I''m trying to use sqlite3 and I''ve followed the steps here :
http://wiki.rubyonrails.org/rails/pages/HowtoUseSQLite
However I get the error above (uninitialized constant API) when trying
to run a migration.
I''m under Windows XP, using cygwin, the sqlite3.dll file is on the lib
directory of my rails app (filemon, an utility that reports file access
attempts
2006 Aug 04
0
How to make prefix_sessions recognizable?
Hello,
i must use prefix to each of my tables for my project right now. Now i''m
facing this session stored in table problem.
i don''t use rake db:sessions:create, but i use script/generate migration
create_myproject_sessions
then
create_table :myproject_sessions do |t|
t.column :myproject_session_id, :string
t.column :data, :text
t.column updated_at, :datetime
end
then
2006 Sep 08
1
(Probably Easy) ActiveRecord help needed!
[Using XP, MySQL 5.0, Ruby 1.8.4]
Hello, this is my first post.
I am new to Ruby, coming from about 6 years of ''import java.util.*''s. I
am using ActiveRecord, both on Rails and outside Rails.
On Rails I have no trouble. Outside is where it gets confusing.
I have created three tables (so far) and their three corresponding
classes. Since I''m having the same
2006 Aug 04
8
Demo in rails2.pdf of add_price migration, PostgreSQL 8.1.4
People,
I''m looking at the migrate example on p 74 of the rails2.pdf
It''s a simple example of using a migration to add a column to
the products table.
Here is a copy of the migration file named 002_add_price.rb
after I generated and then edited it:
class AddPrice < ActiveRecord::Migration
def self.up
add_column :products, :price, :decimal, :precision => 8, :scale
2006 Aug 04
0
Rake migrate errors, but it still works
I get the errors below when running rake migrate, but it still works.
Is there anything to be bothered about? Some appear twice.
All of the below are installed from portage in Gentoo.
me@machine ~/Site $ rake migrate
(in /home/me/Site)
/usr/lib/ruby/gems/1.8/gems/activerecord-1.14.3/lib/active_record/validations.rb:334:
warning: `*'' interpreted as argument prefix