SqlTableName
Usage
To override the default name of the SQL table to which this class is projected, use the following syntax:
Class MyApp.Person Extends %Persistent [ SqlTableName = DBTable ] { //class members }
Where DBTable is a valid SQL identifier.
Details
This keyword specifies the name of the SQL table to which this class is projected. By default, the SQL table name is the same as the class name.
Typically you use this keyword when the class name is a SQL reserved word (not uncommon) or if you want the SQL table to contain characters not supported by class names (such as the “_” character).
Effect on Subclasses
This keyword is not inherited.
Default
If you omit this keyword, the class name is used as the SQL table name.
See Also
-
“Class Definitions” in this book
-
“Defining and Compiling Classes” in Using Caché Objects
-
“Introduction to Compiler Keywords” in Using Caché Objects