I think secondary index could do the trick. 

However, if you need to provide the pagination function, I will go for Konstantin's solution.

On Wed, Nov 16, 2011 at 10:27 PM, Konstantin Naryshkin <konstantinn@a-bb.net> wrote:
Or just have two column families to do it: A CF idToName that has the
userIds as keys and the userName as the only column and a CF nameToId
that has the userNames as keys and the userId as the only column

On Mon, Nov 14, 2011 at 03:50, chovatia jaydeep
<chovatia_jaydeep@yahoo.co.in> wrote:
> Check if Cassandra secondary index meets your requirement.
> Thank you,
> Jaydeep
> ________________________________
> From: Aklin_81 <asdkl93@gmail.com>
> To: user <user@cassandra.apache.org>
> Sent: Sunday, 13 November 2011 12:32 PM
> Subject: Fast lookups for userId to username and vice versa
> I need to create mapping from <userId>(s) to <username>(s) which need to
> provide for fast lookups service ?
> Also I need to provide a mapping from <username> to <userId> inorder to
> implement search functionality in my application.
> What could be a good strategy to implement this ? (I would welcome
> suggestions to use any new technologies if they are really worth for my
> case.)