37 lines
2.8 KiB
HTML
37 lines
2.8 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<html>
|
|
<head>
|
|
<META http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
<LINK rel="stylesheet" type="text/css" href="../../../rzahg/ic.css">
|
|
|
|
<title>Configure JDBC data access</title>
|
|
</head>
|
|
|
|
<BODY>
|
|
<!-- Java sync-link -->
|
|
<SCRIPT LANGUAGE="Javascript" SRC="../../../rzahg/synch.js" TYPE="text/javascript"></SCRIPT>
|
|
|
|
<h5><A NAME="dataccon">Configure JDBC data access</A></h5>
|
|
|
|
<p>You must create a JDBC provider and data source for your application to use to access a database. Perform these steps:</p>
|
|
|
|
<ol>
|
|
<li><p><strong><a href="../sec/seccj2c.htm">(Optional) Configure a J2C authentication data entry</a></strong> in the <em>Security</em> topic.
|
|
<br>If your application is configured using WebSphere Application Server security, and you require a user ID and password to access the database, you can configure a J2C authentication data entry to define authentication data, which includes user identity and passwords. Authentication data entries can be referenced by resource adapters, data sources, and other configurations that require authentication data using an alias.</p>
|
|
<p>During data source creation, the J2C authentication data entry is used as a part of the Component-managed Authentication Alias and Container-managed Authentication Alias fields.</p>
|
|
</li>
|
|
<li><p><strong><a href="datacrtjdbc.htm">Create a JDBC provider and a data source</a>.</strong>
|
|
<br>A JDBC provider represents a JDBC driver. To access a database, your applications use data sources, which use a JDBC driver to access the database.</p>
|
|
</li>
|
|
<li><p>Bind the resource reference.</p></li>
|
|
<li><p><strong><a href="datatest.htm">Test the connection</a></strong> (for non-container-managed persistence usage).
|
|
<br>The test connection service enables developers to test a connection to a data source.</p>
|
|
</li>
|
|
</ol>
|
|
|
|
<p><strong>Note: </strong>You can use a JACL script to automate the above steps. For an example of how to create a JDBC provider and data source using Java Management Extensions (JMX) APIs, see <a href="dataexcrtjdbc.htm">Example: Creating a JDBC provider and data source using Java Management Extensions API and the scripting tool</a>.</p>
|
|
|
|
<p>If your connection is not successful after you complete these steps and review the applicable information, check the SystemOut.log for warning or exception messages. See <a href="../trb/trbvmview.htm">View the Java virtual machine log files</a> in the <em>Troubleshooting</em> topic for more information. You can also use the <a href="http://www-1.ibm.com/support/search/index.html" target="_blank">Technical support search</a> <img src="www.gif" width="18" height="15" align="absbottom" alt="Link outside Information Center" border="0"> to find known problems.</p>
|
|
</body>
|
|
</html>
|