similar to: database connection handles

Displaying 20 results from an estimated 90000 matches similar to: "database connection handles"

2006 Nov 24
0
PostgreSQL search_path and db:structure:dump rake task
Hello! I''ve submitted a patch to work around a problem when multiple schemas are included in the search_path in database.yml for PostgreSQL databases. (Long story short: the pg_dump --schema flag only accepts a single schema.) http://dev.rubyonrails.org/ticket/6665 While I''ve tested the regex pattern used to check for multiple schemas, I''m unsure of how to
2006 Jul 03
13
Remote Postgres is driving me crazy!
Hi guys, I need your help. Here is my database.yml: development: adapter: postgresql database: db username: username password: mypassword # Connect on a TCP socket. Omitted by default since the client uses a # domain socket that doesn''t need configuration. Windows does not have # domain sockets, so uncomment these lines. host: 192.168.22.1 (this is a remote ip in
2006 Mar 07
0
Fwd: [Ruby on Rails] #4112: PostgreSQL views not supported when dumping schema.rb file
I just added a ticket to the Rails Trac about this issue. Is anyone else here running into the same problem? If so, perhaps we can put our heads together to come up with a workable solution. ---------- Forwarded message ---------- From: Ruby on Rails <davidhh@wrath.rubyonrails.com> Date: Mar 7, 2006 7:57 AM Subject: [Ruby on Rails] #4112: PostgreSQL views not supported when dumping
2007 Aug 07
4
Execute additional commands after creating database?
I''m writing some code that accesses some lagacy database on PostgreSQL. Since the old database had some really ughly and weird naming conventions (like CamelCase). To work around this I created a second schema (named rails) in the same database and gave the tables and fields some rails-friendly names. The database user that Rails uses has its search_path set to the rails schema. That way
2005 Oct 28
3
PostgreSQL. Multiply schemas in one database. How to?
Hi all. I am using PostgreSQL in my current project and I have couple of questions on this topic. Previously I have used 3 databases for project. i.e. megaproject_development, megaproject_test and megaproject_development. But I don''t like this variant because of ''rake dump_db_structure'' writes a lot of PostgreSQL specific data for structure file (operators, functions,
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
2006 Jun 22
0
Simple Query of Postgis Posgresql database?
I need to make a simple read-only web query page that allows the user to enter in a longitude and latitude and get a list of areas within which those coordinates occur. I have a postgis (postgresql) databases that contain shape files for county, township, range and section. I can query these databases in the following way from within postgresql in the database county county=# SELECT name_lc
2006 Jun 12
1
Debian vs Ubuntu for a postgresql database + rails
I''m going to be getting a VPS at rimuhosting.com, and it''ll only run postgresql and an app that uses AR/ActionSupport. I always use FreeBSD, but in this case my options are limited to RHEL4, FC5, Debian and Ubuntu. I figure Debian and Ubuntu are probably preferable...so which one should I go with? This will not run an email, ftp, or web server - just postgresql 8.1 plus a Ruby
2010 Apr 07
0
Need help with ActiveWarehouse-ETL-0.9.1 PG connection problem
I am trying to load conversion data into a postgresql database using activewarehouse-etl. I can create a flat file output from the conversion data without problem. However, when I try to load into the table using the information contained in config/database.yml I see this error: /usr/lib64/ruby/gems/1.8/gems/activerecord-2.3.5/lib/active_record/ base.rb:1959:in `method_missing'':
2008 May 05
2
RODBC and schemas
I have found that the "schema.table" syntax used in Postgresql (and Oracle) does not work directly with RODBC. This works library(RODBC) con<-odbcConnect("mydb") d<-sqlQuery(con,"select * from meso.trees") However this does not. d<-sqlFetch(con,"meso.trees") Error in odbcTableExists(channel, sqtable) : ?meso.trees?: table not found on channel
2007 Mar 19
0
PGError "unknown column" on polymorphic association column
Hi all ! This is very strange. I am attempting to get my application running on PostgreSQL (from MySQL), and I get this error: ActiveRecord::StatementInvalid: PGError: ERREUR: la colonne «Party» n'existe pas : SELECT * FROM contact_routes WHERE (routable_type = "Party" AND routable_id = 1000013) ORDER BY position DESC LIMIT 1
2006 Apr 22
0
Connecting to existing postgreSQL database in Win32
I''ve been runnning Perl under Apache for a while but have decided to try using Ruby-on-Rails. My current database is postgreSQL 8.1. I have no problem connecting to it using Perl or PHP 5. However, I''m obviously missing something ''cos no matter what I do I cannot connect to the database from RoR. I have followed all of the instructions I could find and when I start
2006 Jul 30
3
Returning custom error messages in ActionWebService
I want to return my own error messages from an API instead of letting the client see the stack trace. I''m returning a custom structure so I guess I could just put a member in that structure for the error message, although that seems like kind of a hack. Any suggestions? Chris
2006 Feb 09
2
postgres connection problems
Hello, I''m a newbie to rails and I am trying to do the Demo in the November Issue of Linux Journal. Things go fine go fine until I try to connect to my Postgres database (ver 8.1). At this point I get the following error message ---- RoR error and trace back ---- PGError in Admin#index could not connect to server: Permission denied Is the server running on host "localhost"
2007 Oct 05
5
PostgreSQL, templates, and test databases
Hi everyone. I''m having a bit of a problem with an application I''m currently developing with Rails 1.2.3 and PostgreSQL, attempting to use test-first development. Here''s the scenario: * I have the usual three databases, with migrations. Testing has been working beautifully. * I need to store geographic data, so I add PostGIS to all three databases (along with
2009 Sep 25
3
how to time out a query
Hi, I''ve got an activerecord query which takes longer than 100 seconds. I''m using rails 2.2 with postgresql 8.3. http://www.postgresql.org/docs/8.3/static/runtime-config-client.html mentions an option called "statement_timeout" which when set aborts a query which takes longer than x milli seconds. How do I pass this option to AR so that it in turn passes this to
2006 Jan 26
0
If you want to disconnect a database properly, there is the code:)!!!
Hi, We have worked on a problem of connection: Connect to two databases with a single ActiveRecord::Base model class within the same action The main difficulty is how to disconnect the actual connection properly and then let the ActiveRecord establishes a new one. The actual function "remove_connection" removes the connection, but its doesn''t unbind the link between rails and
2014 May 19
0
Can ActiveRecord::Base.connection.schema_search_path be set per process?
I am building an app that every company has it own private schema(Postgresql). For every requisition, I set the Postgres search path in a before_action like this: ActiveRecord::Base.connection.schema_search_path = 'company_id, public' If I have multiple Unicorn workers, and one worker 'A' set the path, while another work 'B' set the path before worker A has finish, I
2006 Jan 13
1
How to disconnect to a database????
Hi, We have experienced some problems with ActiveRecord::Base class of Ruby-Rails. We are building a web-application based on the Ruby-rails framework and the web-application needs to access to difference databases, so we do not pre-define our database accesses in the database.yml file. In fact, we are using the ActiveRecord::Base.establish_connection() to connect to our database, the function
2010 Dec 08
2
Bug in nested transactions in rails 2.3.x
Hello! According to ActiveRecord transactions documentation, User.transaction do User.create(:username => ''Kotori'') User.transaction(:requires_new => true) do User.create(:username => ''Nemu'') raise ActiveRecord::Rollback end end User.find(:all) # => Returns only Kotori But I get both records in database (tested on