Passes the enclosed string or member name as a string to another function.
@NAME (mbrName)
| mbrName | Any valid single member name, dimension name, or a string. |
Analytic Services does not support strings in functions. It treats strings as values or array of values. The @NAME function processes strings.
Example 1
The following example is based on the Sample Basic database. A user defined function is used to retrieve the price from the table below. The user defined function (J_GetPrice) takes two string parameters, time and product name, to return the price for each product.
| MonthName | ProductId | Price |
| Jan | 100-10 | 1.90 |
| Feb | 100-10 | 1.95 |
| Mar | 100-10 | 1.98 |
| Jan | 100-20 | 1.95 |
| Feb | 100-20 | 2.00 |
| Mar | 100-20 | 2.05 |
Price = @J_GetPrice(@NAME(@CURRMBR(Product)),@NAME(@CURRMBR(Year)));
The following report illustrates the above example:
Price Actual Market
Jan Feb Mar
=== === ===
100-10 1.90 1.95 1.98
100-20 1.95 2.00 2.05
Example 2
The following example is based on the Sample Basic database:
"Profit Per Ounce" = Profit/@ATTRIBUTEVAL(@NAME(Ounces));
The @NAME function processes the string “Ounces” before passing it to the @ATTRIBUTEVAL function. This example produces the following report:
Actual Year West
Profit Profit Per Ounce
======== ================
Cola 4593 382.75
| ©2004 Hyperion Solutions Corporation. All Rights Reserved. http://www.hyperion.com |