similar to: establish_connection method

Displaying 20 results from an estimated 100 matches similar to: "establish_connection method"

2006 Jul 24
7
[PATCH] Support for DB Clusters/Replication in ActiveRecord (RFC)
Skipped content of type multipart/alternative-------------- next part -------------- Index: connection_adapters/abstract/connection_specification.rb =================================================================== --- connection_adapters/abstract/connection_specification.rb (revision 4617) +++ connection_adapters/abstract/connection_specification.rb (working copy) @@ -1,10 +1,21 @@ require
2008 Apr 11
1
database adaptor password in production.log
So, as I''m working on migrating my app from Rails 1.2.1 to Rails 1.2.6, suddenly my database adaptor password is showing up in production log on startup. This could be because use " ActiveRecord::Base.allow_concurrency = true" (I know, nobody else does and you''ll tell me not to do it. But I''ve investigated it and it''s working for me, that''s
2007 Jan 11
12
Rails not properly handling Oracle db connections/sesions in dev mode
We are running edge rails with oracle. After a few hundred requests all available sesions are used up. It seems prior connections are being left open. When this happens no one using the installation of Oracle can create a new session until you kill your mongrel/webrick server. Patch #6928 addresses this problem, and i applied it to my vendor rails and it worked. I think, if possible, this
2006 Jan 18
1
Helps!!!!! Rails database connection guru needed!!!!!!!
Hi, I really need help to understand what is happening while Rails connect to a database, (we area actually using postgresql, so my example will be with postgresql) What I understand is Rails is able to connect to different DB. Actually, this is what we want, and we have made some tests, everything is juste fine. However, all these tests lead us to some important questions that we did find the
2012 Jul 17
6
Database connection parameters are tied to the filesystem
HI Guys, I recently tried VERY hard to override the database configuration bassed on ENV vars or actual API calls. This task is almost next to impossible. I know that the database.yml file is parsed as ERB but that is sane for simple ENV replacement if you want to actually change which database adaptor it is (requires extra config/params) it becomes messy. I found
2006 Jul 05
2
Serialized object behaves weird
Hi! I got a class named EinsatzFilter which I serialized to session. Before saving to session it works afterwards I keep getting the message: "undefined method `to_s'' for #<Person:0x38c6ab8>". "Person" is a from ActiveRecord::Base inherited class. Code: class EinsatzFilter include ApplicationHelper attr_reader :personen, :monat, :projekte, :kunde
2006 Jun 26
1
Separate Read and Write Database
Hello, I need to access an mirrored database with one read and one write cluster. Is there a way to tell a model to use two connections? So that all updates etc go to the write database and all read from the read one? This is a fixed set up I can not use MySQL 5.x stuff and additionally i get a token on write, which can be checked on read (and wait for replication) if new data is needed. I
2006 Jun 16
0
Mysql: establish_connection''...development database not conf
I have tried for several hour to get a mysql db connection to work, but have failed so far: This is a cpanel server running Mysql 4.1.19, fcgi with apache. Here is the output from script/console Loading development environment. /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.14.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:194:in
2006 Jan 14
5
New problem with Mac OS X + rails + mysql. Please help!
All, I am working through the ''depot'' sample application from the "Pragmatic Programmers" book on my powerbook. I was going through the install process on http://hivelogic.com/articles/2005/12/01/ ruby_rails_lighttpd_mysql_tiger and it seemed to work fine. But when I try to create the first table, I get the following error, and I have no idea what this means. Any
2006 Jan 14
1
(ActiveRecord::AdapterNotSpecified) Error
All, I am on Mac OS X 10.4, went through all the installation steps for mysql and ruby on rails. Now, I am getting this error when trying to start webrick or when trying to create the tables: /usr/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/ connection_adapters/abstract/connection_specification.rb:73:in `establish_connection'': development database is not configured
2006 May 10
8
dynamic setting of username and password in database.yml
Hello I''ve now read a lot about application-level authentication in Rails, but I need to do database-level authentication. The reason is that my database needs to have the current_user (database current_user, not current_user defined in an ActiveRecord Model) set to execute triggers for automatically updating audit tables. So it is not enough to have a session check against a User
2006 Apr 12
5
Rails talking to MySql (cygwin on Windows XP)
Hello fellow RoR users, I am a newbie and I thought RoR is so easy to set up and that I would be saving so much time -- but I am still waiting to save time because I simply couldn''t get Ruby/Rails to talk to MySQL (5.0.18) at all. Here are the steps that I have examined: 1) I look at dabatbase.yml and put in the right information to talk to the database I have set up (the
2006 Sep 15
2
unable to figure out how to get backgroundrb.yml to be used when starting backgroundrb
i ran rake backgroundrb:setup and modified the default config/backgroundrb.yml file as: --- port: "22223" timer_sleep: 60 load_rails: true environment: production host: localhost database_yml: config/database.yml acl: deny: all allow: localhost 127.0.0.1 order: deny,allow and my database.yml production: adapter: mysql database: chip2_production username: xxxxx password:
2006 Aug 01
7
MySQL binding problem on Max OS X 10.4
Hi all. No matter what I do I can''t get rails to see my MySQL database. All details are below. I really appreciate any assistance. Thanks!!! DETAILS ------- 1. I''m using Rails 1.1.4 with Ruby 1.8.4 on Mac OS X 10.4.7. I have installed the MySQL bindings following the instructions here:
2006 Jan 05
7
HOWTO: Combine fields from 2 two tables in 1 object
Hi all, For a dropdownlist (showing "Company - FirstName Lastname'') I want to fill an object @project_contacts with "Name" from table Companies and "Firstname" and "Lastname" from table contacts. Any idea? Regards, Gerard. -- "Who cares if it doesn''t do anything? It was made with our new Triple-Iso-Bifurcated-Krypton-Gate-MOS
2007 Jul 19
0
locomotive and establish_connection
I am using locomotive for development. My app uses dual databases and hence I have a model that uses a different establish_connection to connect to the db. It seems that locomotive does not support this. Am I correct? If so, does anyone have a different approach to achieve this? thanks. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed
2011 Jul 19
2
ActiveRecord::Base.establish_connection in development and production envs
Hi, guys! Background: I''ve resque workers in my application. These workers do several jobs that associated with DB. In development environment, I''ve no need to provide some additional configuration for db, they are use development database. But then I switching to production env, I set ActiveRecord::Base.establish_connection with my production DB parameters. Problem: When
2012 Aug 31
1
after_fork - ActiveRecord::AdapterNotSpecified
Hi all, I''m fighting with the after_fork hook and my sinatra application. The Sinatra app is using active_record, In my unciron.rb file I''m using preload_app true after_fork do |server, worker| ? defined?(ActiveRecord::Base) and ??? ActiveRecord::Base.establish_connection End but I always get the error: ERROR -- : ActiveRecord::AdapterNotSpecified
2005 Dec 22
0
Getting AdapterNotSpecified on simple script/generate
So even after installing the sqlite3-ruby gem without issues, I still get this error when I try to generate a model... Attempting local installation of ''sqlite3-ruby'' Local gem file not found: sqlite3-ruby*.gem Attempting remote installation of ''sqlite3-ruby'' Select which gem to install for your platform (powerpc-darwin8.3.0) 1. sqlite3-ruby 1.1.0 (mswin32)
2006 May 02
17
Tests just deleted my production Database!!! PLEASE HELP
Running the functional tests has deleted the data in my production database!!! please help!! Using rails 1.1.1 + Oracle. This is my database.yml file : development: adapter: oci host: "V2:1521/TIM" username: salt password: oracle1 test: adapter: oci host: "V2:1521/TIM" username: rectest password: oracletest production: adapter: oci host: