Oracle9i OLAP Developer's Guide to the OLAP DML Release 2 (9.2) Part Number A95298-01 |
|
Selecting Data, 12 of 13
You can set the current status list of a dimension to null (empty status) only when you have explicitly specified that you want null status to be permitted. You can give this permission in either of two ways:
OKNULLSTATUS
option to yes
. This specification indicates that null status should be allowed whenever it occurs except when the IFNONE
argument is present in a LIMIT
command.NULL
keyword in a LIMIT
command to set the status of a particular dimension or valueset to null. You can do this by specifying TO NULL
or KEEP NULL
. This specification indicates that null status should be allowed for this LIMIT
command only.If you have not used either of these two methods to give permission for null status and you execute a LIMIT
command that would result in null status, then the status is not changed to null when the command is executed. Instead, the status remains the same as it was before the command was issued.
You cannot use the IFNONE
and NULL
keywords in the same LIMIT
command.
An IFNONE
argument in a LIMIT
command indicates that you do not want program execution to take its normal course when a dimension status is set to null. Therefore, when IFNONE
is present, a branch is performed to the IFNONE label and the status is not set to null, even if OKNULLSTATUS
is YES
. If the NULL
keyword is present together with IFNONE
, then the inconsistency is signaled with an error.
An error will not be signaled when you try to limit the status of a dimension or valueset that has no values, unless you explicitly list values that do not exist. For example, if you have not added any values to a newly defined dimension WEEK
, then the following command does not cause an error.
LIMIT week TO FIRST 10
However, the following command does cause an error because PETE
is not a value.
LIMIT week TO 'PETE'
Similarly, the following command causes an error because WEEK
does not have a value at position 20.
LIMIT week TO 20
|
Copyright © 2001, 2002 Oracle Corporation. All Rights Reserved. |
|