Embedded SQL and JDBC API in Java Applications - Assessment and Migration

The JDBC API provides access to databases in Java applications. JDBC is a part of the Java platform and it is divided into 2 packages: java.sql and javax.sql.

JDBC Classes and Interfaces

The JDBC API includes the following main Java classes and interfaces:

  • java.sql Package
java.sql.Connection Connection to a specific database
java.sql.PreparedStatement Precompiled SQL statement
java.sql.ResultSet Query result
java.sql.SQLException Information on database errors
java.sql.Timestamp Operations with SQL TIMESTAMP data type

Migration Assessment

Assessment helps estimate the effort and cost of a migration. For conversion of embedded SQL in a Java application, the assessment can involve the following:

  • Identifying Java files containing database access code
  • Identifying embedded SQL statements

SQLines offers the following built-in assessment features:

  • The number of occurrences of import java.sql directives (for each JDBC java.sql class)
  • The list of files containing import java.sql directives
  • The number of lines of code in each Java file and in all files

Using conversion language and report templates you can extend assessment features of SQLines and develop any custom assessment reports.