...
I
Panel |
---|
|
SNULLThis function checks whether a value is unknown Syntax Code Block |
---|
ISNULL(expression) |
Return type Examples Suppose the following data model. Person.name | Person.SequenceNumber |
---|
“Bob” | 654 | “Jane” | ? |
for Bob, ISNULL ( Person.SequenceNumber ) = FALSE for Jane, ISNULL ( Person.SequenceNumber ) = TRUE
|
Panel |
---|
|
ISUNKNOWNThis function replaces a value if that value is unknown. Syntax Code Block |
---|
ISUNKNOWN(expression, value) |
Return type Examples Suppose the following data model. Person.name | Person.SequenceNumber |
---|
“Bob” | 654 | “Jane” | ? | “Mary” | 667 | “Rick” | ? | “Ron” | ? | “Jenny” | 765 |
for Jane, ISUNKNOWN ( Person.SequenceNumber , 999 ) = 999 for Mary, ISUNKNOWN ( Person.SequenceNumber , 999 ) = 667
|
Panel |
---|
|
IS AUse this function to check the type of an instance. The function returns TRUE if the selected instance is of the specified entity. Syntax Code Block |
---|
instance IS A entity_name |
Return type Examples Suppose a domain model in which there is a singleton entity Residence that has a multivalued relation hasRooms with Room . Room is the base entity for singleton Kitchen and not singletons Bedroom and Bathroom . If you want to determine the number of bedrooms is the residence: If you want to determine the number of bathrooms is the residence: |
Panel |
---|
|
TYPE OFUse this function to determine the type of an instance. The function returns the name of the entity. Syntax Code Block |
---|
TYPE OF base_entity |
Return type Examples Suppose a domain model in which there is a singleton entity Residence that has a multivalued relation hasRooms with Room . Room is the base entity for singleton Kitchen and not singletons Bedroom and Bathroom . |
Panel |
---|
|
ISACTIVEUse this function to determine if an instance of a specific type is currently active. Code Block |
---|
ISACTIVE instances [WHERE condition] |
- instances - instances to search
- condition - optional condition to limit the collection of instances to check
Return type Examples Suppose the following data model. instance_id | Person.name | Person.Age |
---|
Person_1 | “Bob” | 14 | Person_2 | “Jane” | 25 | Person_3 | “Mary” | 30 |
- If no instance of Person is activated,
ISACTIVE Person = FALSE - If
Person_1 is active, ISACTIVE Person = TRUE - If
Person_1 is active, ISACTIVE Person WHERE Person.Age >= 18 = FALSE (since Person_1 is excluded by the condition) ISACTIVE system = TRUE (system contains the system attributes and is a singleton. Therefore it is always active)- If no instance of Person is activated, the following expression will fail because Person is not in scope:By using the
ISACTIVE function the expression can be evaluated without error:
|