UltraLite Database User's Guide
Using UltraLite Static Interfaces
Defining SQL statements for your application
When you add SQL statements to a reference database, you assign them to an UltraLite project. By grouping them this way, you can develop multiple applications using the same reference database.
When the UltraLite generator runs against a reference database to generate the database source code files, it takes a project name as an argument and generates the code for the SQL statements in that project.
You can define an UltraLite project using Sybase Central or by directly calling a system stored procedure.
If you are using embedded SQL, the SQL preprocessor defines the UltraLite project for you and you do not need to create it explicitly.
To create an UltraLite project (Sybase Central)
In Sybase Central, connect to your database if you are not already connected.
In the left pane, open the database container.
In the left pane, open the UltraLite Projects folder.
From the File menu, choose New
The UltraLite Project Creation wizard appears.
Enter an UltraLite project name and click Finish to create the project in the database.
For information on UltraLite project naming rules, see ul_add_project system procedure.
To create an UltraLite project (SQL)
From Interactive SQL or another application, enter the following command:
call ul_add_project( 'project-name' )
where project-name is the name of the project.
For more information, see ul_add_project system procedure.
To create an UltraLite project (embedded SQL)
If you are using the embedded SQL interface, specify the UltraLite project name on the SQL Preprocessor command line, and the preprocessor adds the project to the database for you.
For more information, see Building Embedded SQL Applications.
UltraLite project names must conform to the rules for database identifiers. If you include spaces in the project name, do not enclose the name in double quotes, as these are added for you by Sybase Central or the stored procedure.
For more information, see Identifiers.