| <html><head> |
| <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> |
| <title>7. Accessing Multiple Databases</title><link rel="stylesheet" href="css/docbook.css" type="text/css"><base href="display"><meta name="generator" content="DocBook XSL Stylesheets V1.72.0"><link rel="start" href="manual.html" title="Apache OpenJPA 2.0 User's Guide"><link rel="up" href="ref_guide_dbsetup.html" title="Chapter 4. JDBC"><link rel="prev" href="ref_guide_dbsetup_sql92.html" title="6. Setting the SQL Join Syntax"><link rel="next" href="ref_guide_dbsetup_retain.html" title="8. Configuring the Use of JDBC Connections"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">7. |
| Accessing Multiple Databases |
| </th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ref_guide_dbsetup_sql92.html">Prev</a> </td><th width="60%" align="center">Chapter 4. |
| JDBC |
| </th><td width="20%" align="right"> <a accesskey="n" href="ref_guide_dbsetup_retain.html">Next</a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="ref_guide_dbsetup_multidb"></a>7. |
| Accessing Multiple Databases |
| </h2></div></div></div><a class="indexterm" name="d0e23727"></a><p> |
| Through the properties we've covered thus far, you can configure each |
| <code class="classname">EntityManagerFactory</code> to access a different |
| database. If your application accesses multiple databases, we recommend that you |
| maintain a separate persistence unit for each one. This will allow you to easily |
| load the appropriate resource for each database at runtime, and to give the |
| correct configuration file to OpenJPA's command-line tools during development. |
| </p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ref_guide_dbsetup_sql92.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="ref_guide_dbsetup.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="ref_guide_dbsetup_retain.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">6. |
| Setting the SQL Join Syntax |
| </td><td width="20%" align="center"><a accesskey="h" href="manual.html">Home</a></td><td width="40%" align="right" valign="top"> 8. |
| Configuring the Use of JDBC Connections |
| </td></tr></table></div></body></html> |