title: Storing userID in sessions
body: <p>When I read about sessions, I mostly find the userID is stored in the session. I have created a login page that stores the username and status. Assume the username is unique. So when the user logs in, I can output:</p>
  
  <p>Hi, username.</p>
  
  <p>If I have to change something in the database, I can just do:</p>
  
  <pre><code>statement where username= username in the session
  </code></pre>
  
  <p>so why do we have to store the userID in the session?</p>