macro_rules! values { ($($x:expr),*) => { ... }; }
Expand description
Convert given set of tuples into Values
.
let condition = Row::from((col!("id"), col!("name")))
.in_selection(values!((1, "Musti"), (2, "Naukio")));
let query = Select::from_table("cats").so_that(condition);
let (sql, _) = Sqlite::build(query)?;
assert_eq!(
"SELECT `cats`.* FROM `cats` WHERE (`id`,`name`) IN (VALUES (?,?),(?,?))",
sql
);