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.
You can find sample code in the %SQLANYSAMP16%\UltraLite\CustDB\ directory.
Connecting to an UltraLite database
![]() |
Discuter à propos de cette page dans DocCommentXchange.
|
Copyright © 2013, SAP AG ou société affiliée SAP - SAP Sybase SQL Anywhere 16.0 |