add keys and merge