Giter VIP home page Giter VIP logo

rails_on_pg's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

rails_on_pg's Issues

create language plpgsql statement error causes migration fail

Hi,
first, thanks for giving us this nice plugin !
I'm using rails_on_pg in my project and I run into this issue when I try a migration :

When I want to add a funcion, rails_on_pg automatically add a "CREATE LANGUAGE plpgsql" statement before. But if this language has already been created (e.g : by another create_function call before this one), I get an ActiveRecord::StatementInvalid wich cause the transaction to rollback when running rake db:migrate. Though the plugin uses rescue ActiveRecord::StatementInvalid when executing this create language statement.

Note that while using rake db:setup (which is 'db:create', 'db:schema:load', 'db:seed') we don't have the problem since the StatementInvalid is catched in the rescue in this case.

I'm not so familiar with rails migration mechanism so I'm stuck after reaching this point in debugging :/

I put a sample project to test this behavior here : http://github.com/gonzoyumo/rails_on_pg_test
Complete workflow explained in the readme.

I will appreciate your help to solve this issue.

gonzoyumo.

Install command

The install command should be changed in the ext file to:

rails plugin install

I believe that with Rails 3.0 the scritp/ commands became outdated.

Best and thanks for this useful plugin.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.