this part of code im using to Display the entries in the database on index.html
people = db.execute("SELECT * FROM birthdays")
return render_template("index.html", name = people)
birthday database
CREATE TABLE birthdays (
id INTEGER,
name TEXT,
month INTEGER,
day INTEGER,
PRIMARY KEY(id)
and this is the html code i use to display the name, the month , and day
{% for people in name %}
<tr>
<td>{{ people["name"] }}</td>
<td>{{ people["month"] }} / {{people["day"]}}</td>
</tr>
{% endfor %}
can someone explain if i have assign
people = db.execute("SELECT * FROM birthdays")
and the variable name = people
whats the logic behind this loop ?
{% for people in name %}