working on key indexing