The documentation set for this product strives to use bias-free language. For the purposes of this documentation set, bias-free is defined as language that does not imply discrimination based on age, disability, gender, racial identity, ethnic identity, sexual orientation, socioeconomic status, and intersectionality. Exceptions may be present in the documentation due to language that is hardcoded in the user interfaces of the product software, language used based on RFP documentation, or language that is used by a referenced third-party product. Learn more about how Cisco is using Inclusive Language.
This appendix contains the files that you will need to create a Java program that uses Java Database Connectivity (JDBC) to connect to an SQL database, creates and executes an SQL statement, and then retrieves the results. The sample files are described in Table A-1 .
|
|
---|---|
Example A-1 JTest.java |
Main program that allows you to connect to a database, create and execute a statement, and then retrieve the results. |
Example A-2 ConnectionPoolManager.java |
Definition of class ConnectionPoolManager that allows you to connect to the database. |
Example A-3 Switch.java |
Definition of a class switch that allows you to create a statement. |
Example A-4 db.properties |
Database-specific definitions. You must set these values to reflect the JDBC driver used, and the URL, user, and password of the database accessed. |
For an introduction to JDBC in Wikipedia and the JDBC API Guide follow these links:
After you install the JDBC API, you can find the data types for use in statements in the install directory file constant-values.html.
Example A-2 ConnectionPoolManager.java