Although you can create indexes using the SQL CREATE INDEX command the ANSI syntax does not allow index expressions or conditional statements. If you need to create an index with an expression or use conditional statements you will need to use the system procedure sp_CreateIndex. The system procedure also allows you to specify the filename for the index, the CREATE INDEX statement places the index in the structural index file.
The procedure parameters include: Table Name, Index FileName, Tag Name, Expression, Condition, Options and Page Size. In version 9.x an updated version of the procedure (sp_CreateIndex90) includes a parameter for the collation. An example usage of these functions are below:
// Create an index concatenating two fields
EXECUTE PROCEDURE sp_CreateIndex( 'Customer', 'Cust.adi',
'NAME', 'LastName;FirstName', '', 2, 512);
// A collation can be specified for 9.x
EXECUTE PROCEDURE sp_CreateIndex90( 'Customer','Cust.adi',
'NAME', 'LastName;FirstName', '', 2, 512, '' );
The options value is specified as an integer. You set this option by adding together the values for the various options. For instance a compound candidate index would have an option value of 2050 (2 + 2048). The valid options and their values are listed below.
- ADS_DEFAULT = 0
- ADS_UNIQUE = 1
- ADS_COMPOUND = 2
- ADS_CUSTOM = 4
- ADS_DESCENDING = 8
- ADS_CANDIDATE = 2048
UPDATED 31 MAR 2009 – The original opening paragraph is below:
Although you can create indexes using the SQL CREATE INDEX command the ANSI syntax only accounts for single field indexes. If you need to create a multi-segmented index or use conditional statements you will need to use the system procedure sp_CreateIndex.






Generating SQL scripts for creating data dictionary objects is as easy as a right-click. For free tables ARC includes a utility for creating code for the tables. This utility can be used for both free tables and dictionary bound tables. The utility will generate Delphi, C++ Builder and SQL code for generating the table. It will also generate the code to add all of the records to the table after it is created. Although I would only recommend doing this for tables which have only a few records.
Advantage Data Architect has the ability to generate SQL Scripts for any data dictionary object. This allows for simple generation of statements which can be used to add the object in another data dictionary. You can generate the SQL Script by right-clicking on any dictionary object and choosing Generate SQL Script. This functionality is only available for data dictionary objects.


You can also create and remove groups by using the
To make the graphical plan more manageable ARC has three zoom levels available. Simply right click on the Execution Plan tab and choose the zoom level you want. The following screenshots show the various zoom levels ( click for full size images ).

With this option you can export the data directly to a file or preview it on the screen. Additional information about the exported data can be included by specifying the options. The supported export formats are listed in the drop-down combobox, shown on the left.