{"comment":{"created_at":"2011-10-20T09:24:29Z","body":"Hi, this command will likely not be implemented as it is both an O(N) command and one that usually is felt as needed only when there is some error in the data layout design.\r\n\r\nBut the good news is that with scripting in 2.6 you can implement it with very little Lua code if you really need it. However the reason for using a sorted set in this context is that is the right data structure to use. Think about this:\r\n\r\n* If you want LINDEX or alike, you are hoping your list is small enough, otherwise it is unusable form a performance point of view.\r\n* But if your list is small, you can use a sorted set since now with 2.4 they are specially encoded when they are small, so no additional memory is used compared to a list (or very little additional memory).\r\n\r\nConclusion? Use 2.6 scripting if you really want it, but likely you want to change your implementation.\r\n\r\nClosing the issue. Thanks for submitting anyway!\r\n\r\nCheers,\r\nSalvatore","updated_at":"2011-10-20T09:24:29Z","url":"https://api.github.com/repos/antirez/redis/issues/comments/2466486","id":2466486,"user":{"avatar_url":"https://secure.gravatar.com/avatar/7379345fed54f2447537068ed1c2e440?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"7379345fed54f2447537068ed1c2e440","url":"https://api.github.com/users/antirez","id":65632,"login":"antirez"}},"action":"created","issue":{"number":140,"created_at":"2011-10-15T00:06:10Z","pull_request":{"diff_url":null,"patch_url":null,"html_url":null},"body":"Please, add support to determine the index of a member in a list.\r\n\r\nP. S.\r\nI have array with unique numbers stored in the redis list. And there is no reason to use sorted set (overhead, when member equal score :()\r\n\r\nTnx.\r\n","comments":2,"title":"Feature Request: lRank","updated_at":"2011-10-20T09:24:29Z","url":"https://api.github.com/repos/antirez/redis/issues/140","id":1915261,"assignee":null,"milestone":null,"closed_at":"2011-10-20T09:24:29Z","user":{"avatar_url":"https://secure.gravatar.com/avatar/25e9829d1dfda1a8d6159deae73698d0?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"25e9829d1dfda1a8d6159deae73698d0","url":"https://api.github.com/users/belov1985","id":1129317,"login":"belov1985"},"html_url":"https://github.com/antirez/redis/issues/140","labels":[],"state":"closed"},"legacy":{"issue_id":1915261,"comment_id":2466486}}