UltraLiteJ adds basic database functionality to your Java applications and is compatible with BlackBerry smartphones. The UltraLiteJ API contains all the methods required to connect to an UltraLiteJ database, perform schema operations, and maintain data using SQL statements. Advanced operations, such as data encryption and synchronization, are also supported.
The API for each supported platform is stored in the UltraLite.jar file of your UltraLiteJ directory, which is typically located in the UltraLite\UltraLiteJ folder of your SQL Anywhere installation.
When creating a basic UltraLiteJ application, you typically complete the following tasks:
A Configuration object defines where the database is located. It also sets the username and password. Variations of the Configuration object are available for different devices and for non-persistent database stores. See Configuration interface.
A Connection object connects to an UltraLiteJ database using the specifications defined in the Configuration object. If the database does not exist, it is created automatically. See Connection interface.
The schema methods provided by the Connection object allow you to create tables, columns, indexes, and foreign keys. See schemaCreateBegin function.
A PreparedStatement object queries the database associated with the Connection object. It accepts supported SQL statements, which are passed as Strings. With a PreparedStatement object, you can update the contents of the database. See PreparedStatement interface.
ResultSet objects are created when the Connection object executes a PreparedStatement that contains a SQL SELECT statement. With a ResultSet object, you can view the table contents of the database. See ResultSet interface.
When setting up an UltraLiteJ application in your preferred Java IDE, make sure that your project is correctly configured to use the UltraLite.jar resource file, which is located in your UltraLiteJ directory.
Use the following statement to import the UltraLiteJ package into your Java file:
import ianywhere.ultralitej.*; |
Send feedback about this page via email or DocCommentXchange | Copyright © 2008, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.0 |