Advertisement
Guest User

Untitled

a guest
Apr 3rd, 2020
223
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.46 KB | None | 0 0
  1. def validateLogin():
  2.     global username
  3.     global password
  4.     username_text = username.get()
  5.     password_text = password.get()
  6.    
  7.     with sqlite3.connect("Timetable.db") as db:
  8.         cursor = db.cursor()
  9.     find_user = ("SELECT * FROM StudentInformation WHERE username = ? AND password = ?")
  10.     cursor.execute(find_user,[(username_text),(password_text)])
  11.     results = cursor.fetchall()
  12.     if results:
  13.         success()
  14.     else:
  15.         notFound()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement