Thank you
Now I got it.
Now I can see that the thing that made it look so confusing was the fact that they used the term "persistent identity" in two different meanings:
First as a noun, the primary key value of the instance.
And then as an action, the act of comparing two instances by using the equals() method on their PK objects (or their equivalent wrapper objects if the PK are primitives).
But I think you did not phrase it correctly. You wrote: "if and only if pk of the object .equals() the pk of the record in the database."
But in order to verify "persistent identity", Hibernate does not do equals() between the pk of the object and the pk of the record in the db. The record in the db is not a Java object at all so it cannot be an argument of equals(). The "persistent identity" takes place (just like the Java identity) between two instances. So in order to verify "persistent identity" between two instances, Hibernate calls equals() between their PKs.
What Hibernate guarantees is that for two persistent instances, "persistent identity" is true if and only if instance1==instance2. Which is going to prevent having two persistent instances with the same value of PK only if we override the PK's equals() & hashCode().
[ November 13, 2007: Message edited by: Joseph Sweet ]