Skip to content

Not clearing all bindings #169

Open
Open
@zauguin

Description

@zauguin

Often we need a statement where only some bound parameters change with every use.
Currently we clear bindings every time we reset the bindings so we have to bind all parameters again after every usage.
This gets complicated if you want to pass the prepared statement to another function without all the parameters you want to use every time.

Maybe we could make clearing the bindings optional? Or does anyone has an idea for a nice interface which allows reusing the bindings?

I thought about adding a method .fix_parameters(n) which indicates to no longer modify/clear the first n parameters. There is no sqlite3 function for clearing a subset of all bound parameters, but we could probably emulate this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions