Insert data into the database table `branch_details`.
(
conn: &mut mysql::PooledConn,
my_branch_name: String,
my_location: String,
)
| 200 | |
| 201 | /// Insert data into the database table `branch_details`. |
| 202 | fn insert_branch_data( |
| 203 | conn: &mut mysql::PooledConn, |
| 204 | my_branch_name: String, |
| 205 | my_location: String, |
| 206 | ) -> mysql::error::Result<u64> { |
| 207 | conn.exec_drop( |
| 208 | " |
| 209 | INSERT INTO branch_details (branch_name, location) |
| 210 | VALUES (:branch_name, :location) |
| 211 | ", |
| 212 | params! { |
| 213 | "branch_name" => my_branch_name, |
| 214 | "location" => my_location, |
| 215 | }, |
| 216 | ) |
| 217 | .map(|_| conn.last_insert_id()) |
| 218 | } |
| 219 | |
| 220 | /// Insert data into the database table `teller_details`. |
| 221 | fn insert_teller_data( |