I have the following scenario:
I've a database schema per user in my application(an online ERP/CRM).
All the schemas have the same tables, I would like to know how to map it in my persistence.xml file.
If I need to specify a jta-data-source I'm hardcoding the client for that persistence unit.
Do I need to create a persistence-unit per client and map all the classes in all of my persistence-units ?
I'm using Jboss Seam.
I already created a factory that creates the correct EntityManagerFactory for me.
So my problem, is more specifically, the jta-data-source.
Binding it to my persistece-unit will hardcoded it and make it available just for one client.
Is there some one to do around this ?