Please read the documentation of the session extension. Primary keys are not arbitrary. Your second example would simply not worked like intended because if you merge with external data the rowid is not known. Sory for the short answer, I explained it already in a different post in this thread. There is also a whole thread about it.