Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.
UltraLite applications must connect to the database before performing operations on its data.
The ULDatabaseManager class is used to open a connection to a database. The ULDatabaseManager class returns a non-null ULConnection object when a connection is established. Use the ULConnection object to perform the following tasks:
Commit or roll back transactions.
Synchronize data with a MobiLink server.
Access tables in the database.
Work with SQL statements.
Handle errors in your application.
Ensure you specify a writable path for the database file. Use the NSSearchPathForDirectoriesInDomains method to query the NSDocumentDirectory, for example.
Each connection and all objects created from it should be used by a single thread. If an application requires multiple threads accessing the UltraLite database, each thread requires a separate connection.