I want to use postgres db for my local and production environment both. How should my gemfile look like for this case? Should I completely remove sqlite and just put gem pg or the development and production environment is required with pg? Please help.
On Mac OS X 10.6.8, I get the following error when trying gem install pg. Trying to push my Rails website to Heroku. A pretty standard install of Ruby 1.9.3p194. $ cat /Users/me/.rvm/gems/ruby-1.9.3-p194\@ucode/gems/pg-0.15.1/ext/gem_make.out /Users/me/.rvm/rubies/ruby-1.9.3-p194/bin/ruby extconf.rb checking for pg_config… no No pg_config… trying anyway. If building fails, please try again with –with-pg-config=/path/to/pg_config checking for libpq-fe.h… no […]
I’m trying to install PostgreSQL’s pg gem for Ruby. I issued the following command: gem install pg I installed Ruby 1.9.2 using RVM. The above command shows me the following error. The error is : Building native extensions. This could take a while… ERROR: Error installing pg: ERROR: Failed to build gem native extension. /home/User/.rvm/rubies/ruby-1.9.2-preview3/bin/ruby […]
I have installed following gems: actionmailer (2.3.8) actionpack (2.3.8) activerecord (2.3.8) activeresource (2.3.8) activesupport (2.3.8) open4 (1.0.1) pg (0.9.0) rack (1.1.0) rails (2.3.8) rake (0.8.7) My application uses postgres as db and pg gem and it had been working fine by the time I done rake rails:freeze:gems rake gems:unpack It copied rails and pg gem […]
I’m trying to install the postgres gem “pg” in my rack/bundler app and keep failing when attempting to install through RubyMine. Fetching gem metadata from https://rubygems.org/……… Fetching gem metadata from https://rubygems.org/.. Resolving dependencies… Using addressable (2.3.5) Using bcrypt-ruby (3.1.2) Using data_objects (0.10.13) Using dm-core (1.2.1) Using dm-aggregates (1.2.0) Using dm-constraints (1.2.0) Using dm-migrations (1.2.0) Using […]
I’m on Mac OS 10.7.4, and I have the latest version of Xcode and the Command Line Tools installed. I’m getting an error (shown below) when I try to “gem install pg“: gem install pg Building native extensions. This could take a while… ERROR: Error installing pg: ERROR: Failed to build gem native extension. /Users/rdp/.rvm/rubies/ruby-1.9.3-p125/bin/ruby […]
I’ve looked all the solutions in the internet for this, reinstalled everything and still nothing… When i do gem install pg i get: Building native extensions. This could take a while… ERROR: Error installing pg: ERROR: Failed to build gem native extension. /Users/henriquedubugras/.rvm/rubies/ruby-1.9.3-p194/bin/ruby extconf.rb –with-pgsql->lib=/usr/local/Cellar/postgresql/9.2.1/lib –with-pg->config=/usr/local/Cellar/postgresql/9.2.1/bin/pg_config Using config values from /usr/local/Cellar/postgresql/9.2.1/bin/pg_config checking for libpq-fe.h… * […]
I have changed database from postgresql to mysql, but I don’t know how to transfer data from one to other. Does anyone know any command by which I can copy/migrate my database from postgresql to mysql?
I am using pg gem pg-0.17.1-x86-mingw32. It is working fine when i am connecting it from my ruby codes.But when i am trying to connect it via rails apps, it gives me an error:: “Specified ‘postgresql‘ for database adapter, but the gem is not loaded. Add gem ‘pg’ to your Gemfile.” I am gettigng this […]
I have a method that runs through an excel spreadsheet and puts those values into an array then into PostgreSQL. Everything runs fine but the cell values that hold dates are being returned as doubles. How can I get the date values? Also what if I don’t know when a date value will appear in […]