Drone Pemula Murah Visuo XS816 XS809SSatu2nya Drone dibawah 1juta dgn camera 4K dual, dan bisa terbang +/- 20menit nonstop. Dual Camera ; camera depan & bawah sehingga tidak dibutuhkan lagi wide angel camera yang menjadikan image terlihat oval Buy |
from django.db import connections
def dictfetchall(cursor):
"Return all rows from a cursor as a dict"
columns = [col[0] for col in cursor.description]
return [
dict(zip(columns, row))
for row in cursor.fetchall()
]
def get_list_user():
with connections['example_db'].cursor() as cursor:
cursor.execute("""select * from users """)
connection.close()
row = dictfetchall(cursor)
return row
for x in get_list_user():
print(x['username'])
good luck ...!
Baca artikel lainya: