GetReqEntityDefNames
Description
Returns the names of the state-based record types in the current database's schema.
State-based record types are templates for state-based records. Most databases have at least one state-based record type defining the type of data stored by the database. The database may also have several supporting stateless record type containing secondary information.
Typically, the return value contains at least one name; however, the return value can be an empty Variant if no state-based record types exist in the schema.
After
using this method to get the list of names, you can retrieve the EntityDef Object for a given
record type by calling the GetEntityDef method.
Syntax
Perl
$sessionObj->GetReqEntityDefNames();
- Identifier
- Description
- session
- The Session object that represents the current database-access session.
- Return value
-
A reference to an array of strings is returned.
Example
Perl
$sessionObj = $entity->GetSession();
#Get the names of the state-based record types.
$entityDefNames = $sessionObj->GetReqEntityDefNames();
#Iterate over the state-based record types
foreach $name ( @$entityDefNames){
print $name, "\n";
$entityDefObj = $session->GetEntityDef( $name);
# Do something with the EntityDef object
# ...
}