WordPress get results in key value pair form

I am new to wordpress
How to get key value pair in wordpress select sql query
expected result is array(2 => om ,5 => jay)
what i get is array(0 => om ,1 => jay)

Read more here: WordPress get results in key value pair form

Leave a Reply

Your email address will not be published. Required fields are marked *