O'Reilly logo
  • Gangadhara Melukote thinks this is interesting:

It is undefined what should happen if two queries in the same persistence unit have the same name, but it is likely that either deployment of the application will fail or one will overwrite the other, leading to unpredictable results at runtime.

From

Cover of Pro JPA 2, Second Edition

Note

Duplicate query within same persistence unit.