I am practicing CRUD using Flask, when I update a record I would like the data from that record to be populated in a form in my update.html for editing. I was able to populate the other fields but I cannot do so with the select field. What am I missing?
This is the rendered page showing a table with data from the database:
When I click on update, it brings me to an update page where the data are passed to the update fields to make it easier for editing. As you can see here, the sex select field is not populated.
This is what I have on my update route:
And this is my update.html showing the select field in question.