As explained in the Java application development page, a Java application will define its database schema as native Java classes with the
@Persistent
annotation, then specify optional support libraries in the Database constructor call. Memory devices and database parameters are specified in the Database.Parameters object and Database.Device array passed to the open()
method of class Database. The difference in eXtremeSQL applications is that instead of a Connection object, a SqlLocalConnection or SqlRemoteConnection is instantiated by Database methodconnectSql()
to initialize the SQL engine which is then used for all SQL database access through methodsexecuteQuery()
andexecuteStatement()
.Processing SQL Queries
The classes SqlResultSet and SqlTuple are provided for processing query results. Typically a SqlResultSet will be instantiated by calling
executeQuery()
with aselect
statement; then a for loop will be used to iterate the result set. The SqlTuple class is used to process the current result set row.Executing SQL Statements
The
executeStatement()
method is called with aninsert, update
ordelete
statement to modify database contents.eXtremeSQL Application Implementation Details
Please use the links in the table below for implementation examples:
Example A simple Java application example Misc Details Miscellaneous Java Implementation details Transactions Managing SQL transactions in Java SqlAggregator Instructions for using the SqlAggregator class