Welcome Guest, Not a member yet? Register   Sign In
Get special record position in records
#5

(02-24-2018, 12:21 PM)Wouter60 Wrote: It's impossible that the query gives this result, unless you add "DESC" to the ORDER BY clause.

Convert the result to an array. Then do an array_search for "Sara". It will give you the array key. Because arrays are zero-based, add 1 to the key to determine Sara's position.

Hey do you can help about below result?
I need define level for each user with his score
Example if user's score is 25 so level is 6
Thanks
Level 1: 0
Level 2: 5
Level 3: 10
Level 4: 15
Level 5: 20
Level 6: 25
Level 7: 30
Level 8: 35
Level 9: 40
Level 10: 45
Reply


Messages In This Thread
RE: Get special record position in records - by omid_student - 02-24-2018, 11:06 PM



Theme © iAndrew 2016 - Forum software by © MyBB