Fix error in SQL where a string was expected bit a number was provided
The SQL had to have quotes '', but it didn't. This caused some DNIs that started with 0 (`09950031`) to be casted into `9950031`
This commit is contained in:
parent
b2774f7783
commit
d474b8bb55
@ -88,7 +88,7 @@ impl RegisterCreate {
|
||||
} else {
|
||||
let res = sqlx::query!(
|
||||
"SELECT MAX(register_code) AS max FROM register
|
||||
WHERE register_course_id = ?",
|
||||
WHERE register_course_id = '?'",
|
||||
course_id
|
||||
)
|
||||
.fetch_one(db)
|
||||
|
Loading…
Reference in New Issue
Block a user