Module mysql.protocol.commands
Commands that are expected to return a result set - queries - have distinctive
methods that are enforced. That is it will be an error to call such a method
with an SQL command that does not produce a result set. So for commands like
SELECT, use the query
functions. For other commands, like
INSERT/UPDATE/CREATE/etc, use exec
.
Functions
Name |
Description |
exec
|
Execute a one-off SQL command.
|
query
|
Execute a one-off SQL command for the case where you expect a result set,
and want to deal with it a row at a time.
|
queryRow
|
Executes a one-off SQL command and returns the first row received, or null
if none. Useful for the case where you expect a (possibly empty) result set,
and you're either only expecting one row, or only care about the first row.
|
queryRowTuple
|
Execute a one-off SQL command to place result values into a set of D variables.
|
querySet
|
Execute a one-off SQL command for the case where you expect a result set,
and want it all at once.
|
queryValue
|
Executes a one-off SQL command and returns a single value: The the first column
of the first row received. Useful for the case where you expect a
(possibly empty) result set, and you're either only expecting one value, or
only care about the first value.
|
Structs
Name |
Description |
Command
|
Encapsulation of an SQL command or query.
|
Aliases
Name |
Type |
Description |
queryResult
|
|
Execute a one-off SQL command for the case where you expect a result set,
and want it all at once.
|
querySequence
|
|
Execute a one-off SQL command for the case where you expect a result set,
and want to deal with it a row at a time.
|
queryTuple
|
|
Execute a one-off SQL command to place result values into a set of D variables.
|