1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
use Operation;
use cratestmt;
/// Executes a SQL statement against the database.
///
/// Only sent to SQL-capable drivers (those with [`Capability::sql`](super::super::Capability)
/// set to `true`). The statement is a fully lowered [`stmt::Statement`] that
/// the SQL serialization layer converts into a backend-specific SQL string.
///
/// # Examples
///
/// ```ignore
/// use toasty_core::driver::operation::{QuerySql, Operation};
///
/// let op = QuerySql {
/// stmt: sql_statement,
/// ret: Some(vec![stmt::Type::String, stmt::Type::I64]),
/// last_insert_id_hack: None,
/// };
/// let operation: Operation = op.into();
/// assert!(operation.is_query_sql());
/// ```