Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Using named arguments in queries using thepg_named_args crate #1107

Open
@rudolphfroger

Description

@rudolphfroger

Hi,

Thanks for all the work on rust-postgres!

We've created a new crate which allows one to use named arguments on queries. This is achieved using a macro which rewrites the named arguments into positional arguments. This crate is specifically aimed at supporting rust-postgres because it outputs the query and array exactly as needed.

This crate happily lives on it's own, but it may be nice to point people towards the possibility of using named arguments in the tokio-postgres documentation. Would you be willing to add such a reference to your documentation and/or README?

The docs can be found at:https://docs.rs/pg_named_args/. This includes some examples on how to use it. We've been using this internally for some time, and it works great for us, especially once you have more than a few arguments.

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


      [8]ページ先頭

      ©2009-2025 Movatter.jp