Images didn't work... can't edit... see them here...
Just found it out... Envers is looking for an audited version of that referenced entity. But if envers has been introduced in the middle of a project and that entity has never been updated using Hibernate the audited version is not yet existing. So it fails to load that reference. The full model only works if for every audited entity an initial revision exists in the database. That revision must be less or equal the one that is queried! Damn... how will I fill my tables now?
well, you can fill in the audit tables with data that has the revision equal to 1. Should work fine. (And create a 1 revision in the rev tables, of course).
Thanks... that was exactly what we did, using a procedure to fill in missing data in the version tables.