I have a table in which I want to retrieve the table as follow.
Login Name Parent User Email ID Mobile No
abc abc_parent email@example.com 9999999999
MySql Table as follow in tbl_users
I am having issue as mentioned on the top, I am not able to retrieve the data for parent user as abc_parent, am able to achieve to get parent user id not the parent user loginname as all loginnames come in single column and ids come in first 2 columns.
How can I show the parent user loginname in place of parent_user id.
Currently, i use the following code.
SELECT * FROM tbl_users where status_id='2'
any help will be appreciated, thanks