ardb.cfg or ardb.conf
The ardb.cfg (ardb.conf) file contains SQL clauses that administrators can append to SQL statements issued by AR System when a form, field, or index is created or modified.
Create this file in your configuration directory:
- (Windows default) ARSystemServerInstallDir\Conf
- (UNIX default) ARSystemServerInstallDir/conf
When you create a form, field, or index, AR System references the ardb configuration file for clauses to append to the SQL statement. If it finds no matching information, AR System creates the form, field, or index as it normally would. If it finds matching information, it appends the specified clause to the SQL statement that creates the form, field, or index.
The format of this file is organized by forms.
To create an ardb.cfg (ardb.conf) file
Enter a line in the file for the name of the form and a line for the clause you want added to the CREATE statement:
Form: formName
Clause: clauseWhen you use Developer Studio to change the name of a form, the ardb configuration file is automatically updated to match the new name.
- Include field clause information below the applicable form information:
- Add a field line with an open brace:
Field {
Include a space between Field and the open brace. - Add a line for the field ID:
Id: fieldID - Add a line for the SQL clause:
Clause: clause
The clause must be on one line because no new-line characters are allowed. - Place the closing brace in its own line below the SQL clause line.
- Add a field line with an open brace:
- Include index clause information:
- Add an index line with an open brace:
Index {
Include a space between Index and the open brace. - Add a line for the field IDs in the index:
Id: indexID
If an index contains multiple fields, add several field ID lines before the clause for that index. - Add a line for the SQL clause:
Clause: clause
The clause must be on one line because no new-line characters are allowed.
Clauses that you specify for the tables of a form are not automatically attached to any index you create for that form. You must specify the clause in the index clause. For example, if you specify that a form is to reside in a specific part of your database and you want an index for that form to reside in the same space, you must specify the clause for both the form and index. - Place the closing brace in its own line below the index clause line.
The file looks something like this:
Form: formName
Clause: clause
Field {
Id: fieldID
Clause: clause
}
Index {
Id: index_ID
Id: index_ID
Clause: clause
}
Leading spaces in the ardb configuration file are ignored, so you might want to add them to keep your file organized.
When you create or update the ardb.cfg (ardb.conf) file, the changes do not occur immediately. They occur when the table (or index) is restructured.
- Add an index line with an open brace:
Synopsis
Windows: ARSystemServerInstallDir\Conf\ardb.cfg
UNIX: ARSystemServerInstallDir/conf/ardb.conf
Examples
The following example shows ardb configuration file information for the HD-Answer form on an Oracle database. The tables for the HD-Answer form are built on segment two. The indexes include the Submitter (ID 2), Status (ID 7), and Assigned To (ID 4) fields. The clauses for the indexes instruct the database to leave 70 percent of each index free for updates and insertions.
Form:HD-Answer
Clause:TABLESPACE seg2
Field {
Id:536870913
Clause: NOT FOR REPLICATION
}
Index {
Id:2
Id:7
Clause:PCTFREE 70
}
Index {
Id:4
Clause:PCTFREE 70
}
The following examples show how you can use the ardb.cfg (ardb.conf) file to create indexes using the Oracle UPPER function:
- To specify that all indexes created for a form should be functional indexes, use this syntax
Form: formName
Index {
Oracle-All-Upper-Index
} - To create a single functional index on a specific field, use this syntax:
Form: formName
Index{
Id: fieldID
Oracle-Upper-Index
} - To create a functional composite index, use this syntax:
Form: formName
Index {
Id: field_ID
Id: field_ID
Oracle-Upper-Index
}