Use integer primary key instead of dedicated index in temporary node database

This reduces size of the temporary sqlite node database and is also
slightly faster (5%) than the separate index.