Inserts all elements of a key array in index, still need a good unique function