There is no spec defined means to test for table existence. However,
if you know the table name build and execute a native query selecting
from the table. If a Persistence exception occurs then the table does
not exist. If you do not know the table name you can also execute a
JPQL query for the Entity and check for a Persistence Exception.
--Gordon
Farrukh Najmi wrote:
>
> What is the best way for my JPA client to check for existence of a table?
> I did not find anything in the archives on this. TIA.
>