Ch.Query (Ch v0.7.0)
View SourceQuery struct wrapping the SQL statement.
Summary
Types
@type command() ::
:undrop
| :move
| :watch
| :use
| :truncate
| :set
| :exchange
| :rename
| :optimize
| :kill
| :exists
| :drop
| :detach
| :describe
| :check
| :attach
| :update
| :revoke
| :explain
| :grant
| :select
| :show
| :system
| :delete
| :alter
| :create
| :insert
| :select
Atom representing the type of SQL command.
Derived automatically from the start of the SQL statement (e.g., "SELECT ..." -> :select),
or provided explicitly via options.
@type t() :: %Ch.Query{ command: command(), decode: boolean(), encode: boolean(), multipart: boolean(), statement: iodata() }
The Query struct.
Fields
:statement- The SQL statement to be executed (asiodata/0).:command- The detected or enforced SQL command type (e.g.,:select,:insert).:encode- Whether to encode parameters (defaults totrue).:decode- Whether to decode the response (defaults totrue).:multipart- Whether to usemultipart/form-datafor the request (defaults tofalse).