Skip to content

Execute statement with variable number of parameters? #312

Description

@arthurmilliken

I'm a rust newbie, so please forgive my ignorance if this is a stupid question...

How do I execute statements with a variable number of parameters? Let's say that the statement is:

"INSERT INTO TableName(ColumnA, ColumnB, ColumnC) VALUES (?1, ?2, ?3)"

But TableName, Columns, and number of columns are not known at compile time. Is there a way of coercing an iterator over a collection of strings into a &[&ToSql] type?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions