Code Monkey home page Code Monkey logo

Comments (3)

haizaar avatar haizaar commented on July 22, 2024

Could I still avoid executting a commit after exiting the managed context?

Nothing in momoko lib calls COMMIT for you. I'm not sure why you believe it happens (may be Postgres does it behind the scenes in some way - I'm not much familiar with this DB). BTW, there is Connection.transaction method, that executes a list of statements and commits/rolls back. Does it help you?

Rolling back - I see indeed no rollback method on the connection

Again, there are no helper methods like Connection.commit and Connection.rollback - you can call execute with appropriate statements or extend connection class to add this methods (currently it will requires monkey-patching the imported package, but I can extend Pool to accept ConnectionClass in constructor).

After retrieving a cursor from yield pool.execute('select something') I'll get back a cursor...

Are named cursors what you are after?

from momoko.

haizaar avatar haizaar commented on July 22, 2024

Closing this discussion due to inactivity. Feel free to reopen.

from momoko.

vladiibine avatar vladiibine commented on July 22, 2024

Yeah, I'm still thinking about it. If I have anything interesting I'll let you know. Thanks for the support! :)

from momoko.

Related Issues (20)

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.