Command<P> class

A command that mutates data (INSERT, UPDATE, DELETE).

Implementers

Constructors

Command(String sql, {dynamic params})
const

Properties

hashCode → int
The hash code for this object.
no setterinherited
params → dynamic
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

apply(P? p) → (String, Map<String, Object?>)
Returns the SQL string and the mapped parameters for this command.
getSql(P? p) → String
Returns the SQL string for this command. Subclasses can override this to generate SQL based on the parameters p.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
returning<R extends Record>(ResultSchema schema, {List<String>? columns}) → Query<P, R>
Creates a query from this command with a RETURNING clause.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

static(String sql) → Command<void>
Factory for static mutations.