Oracle® OLAP DML Reference 10g Release 2 (10.2) Part Number B14346-01 |
|
|
View PDF |
The CHARLIST function transforms an expression into a multiline text value with a separate line for each value of the original expression.
Return Value
NTEXT
when the expression is NTEXT
; otherwise, TEXT.
Syntax
CHARLIST(expression [dimensions])
Arguments
The expression to be transformed into a multiline text value. When the expression has a data type other than TEXT
or NTEXT
, CHARLIST automatically converts the expression to TEXT
.
The dimensions of the return value. When you do not specify a dimension, CHARLIST returns a single value. When you provide one or more dimensions for the return value, CHARLIST returns a multiline text value for each value in the current status list of the specified dimension. Each dimension must be an actual dimension of the expression; it cannot be a related or base dimension.
Examples
Example 8-46 Deleting Workspace Objects
You can use CHARLIST with the NAME dimension to create lists of workspace objects. Suppose you want to delete all objects of a certain type in your workspace, for example, all worksheets. You can use CHARLIST and an ampersand (&
) to do this.
LIMIT NAME TO OBJ(TYPE) EQ 'WORKSHEET' DELETE &CHARLIST(NAME)
Example 8-47 Creating a List of Top Sales People
Assume you have stored the names of the sales people who sold the most for each product in product.memo
, a text variable with the dimensions of product
and . You then want to create a list of top sales people broken out by product. To do this, you can created a variable dimensioned by product and then use CHARLIST with the product to create a separate list of all of the top sales people for each product.
DEFINE topsales VARIABLE TEXT <product> topsales = CHARLIST(product.memo product)