Skip to content

Translate simple queries into prepared statements automatically #1313

Description

@levkk

Convert the simple protocol and unnamed prepared statements into named prepared statements. This allows apps that don't / can't turn on prepared statements due to some driver/other limitation to take advantage of them in production, with a somewhat low overhead of parsing each query.

Example

Query(SELECT * FROM users WHERE id = 5;)

becomes

Parse(__pgdog_1, SELECT * FROM users WHERE id = $1;)
Bind(__pgdog_1, 5)
Execute
Sync

and all subsequent executions become

Bind(__pgdog_1, 5)
Execute
Sync

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bleeding edgeExciting new frontier stuff.

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions