1/ Create new user using Admin > User > Add a new user
2/ Examine the last login value from the db, e.g. SELECT username, lastlogin FROM mdl_user WHERE username = 'newuser'; (it will be zero)
3/ Login as the new user
4/ Examine the last login value from the db (it is still 0) e.g. SELECT username, lastlogin FROM mdl_user WHERE username = 'newuser'; (it will be zero)
5/ Logout as the new user
6/ Examine the last login value from the db (it is still 0) e.g. SELECT username, lastlogin FROM mdl_user WHERE username = 'newuser'; (it will be zero)
7/ Login as the new user again
8/ Examine the last login value from the DB - it is now set.
Expected result:
Last login value is updated a stage 4
1/ Create new user using Admin > User > Add a new user
2/ Examine the last login value from the db, e.g. SELECT username, lastlogin FROM mdl_user WHERE username = 'newuser'; (it will be zero)
3/ Login as the new user
4/ Examine the last login value from the db (it is still 0) e.g. SELECT username, lastlogin FROM mdl_user WHERE username = 'newuser'; (it will be zero)
5/ Logout as the new user
6/ Examine the last login value from the db (it is still 0) e.g. SELECT username, lastlogin FROM mdl_user WHERE username = 'newuser'; (it will be zero)
7/ Login as the new user again
8/ Examine the last login value from the DB - it is now set.
Expected result:
Last login value is updated a stage 4
It requires a second login to be updated.
has a non-specific relationship to
MDL-22481Unexpected behavior of "Last Login" advanced search field
Closed
is duplicated by
MDL-34901User's first access value set to lastmodified rather than actual login time