Reputation: 13
I have a database table with all system users and I would like to list all users however the first in the select query must be the user which is the currently logged in user.
For example: say I have 7 users registered and the currently logged in user is 'bob', then when I call the select statement to list the users it would look like:
bob
other_user
other_user
other_user
other_user
other_user
other_user
The tbl_user columns
user_id
user_name
user_pass
user_email
user_gender
user_profilepic
forgotten_answer
log_in
Any help is appreciated. Thank you!
Current select statement is:
SELECT * FROM tbl_user
which basically selects all users unordered
Upvotes: 0
Views: 496