set x 10 incr x => 11 incr x => 12

id = incr nextId => 100 set obj_<id> "My new object"

id = incr NextId => 1 set news_url_<id> "http://foobar.org" set news_title_<id> "My foobar story" push mylist 1



id = incr NextId => 2 set news_url_<id> "http://antirez.com" set news_title_<id> "The blog you are reading right now" push mylist 2



id = incr NextId => 3 set news_url_<id> "http://someothersite.com" set news_title_<id> "Some Other Site" push mylist 3

Sorting and weight keys

set score_1 124 set score_2 4461 set score_3 -50

sort mylist by score_* => 3 1 2

Sorting into a distributed environment: key tags

Hash(mylist[homenews]) == Hash(score_10_[homenews]) == Hash(score_20_[homenews])

Implementation