Usage Note 20421: How to split up large cube data with MDX syntax to allow SAS to read the data
Attempting to read large cube data via SAS/ACCESS® Interface to OLEDB with PROC SQL and MDX syntax can result in a hang. Splitting the cube data into pieces on the server side using MDX functions may help.
A coule of examples are below:
/* Example One: Using Tail to return the last 5 months*/
SELECT NON EMPTY
{[Measures].[QuantitySUM]} ON COLUMNS, Tail({DESCENDANTS
([Time].[YMD_EU].[All YMD_EU].lastchild,
[Time].[YMD_EU].[Month_num])},5) ON ROWS
FROM [OrionCube]
/* Example Two: Using Tail to return the last 5 months of 2001 */
SELECT NON EMPTY
{[Measures].[QuantitySUM]} ON COLUMNS,
Tail({[Time].[YMD_EU].[All YMD_EU].[2001].Children},5) ON ROWS
FROM [OrionCube]
* Example Three; Displaying the top 50% of Clothes Items in the Product
Category for 2002 */
/* Using the TOPPERCENT function
SELECT
{[Time].[YQM].[All YQM].[2002] } ON COLUMNS ,
{TOPPERCENT([Product].[All Product].[Clothes & Shoes].[Clothes].Children
,50,[Measures].[Total_Retail_PriceSUM] ) } ON ROWS
FROM [OrionStar]
WHERE [Measures].[Total_Retail_PriceSUM]
/* Example Four; Displaying the bottom 25% of Clothes Items in the Product Category for 2002 */
/* Using the BOTTOMPERCENT function */
SELECT
{[Time].[YQM].[All YQM].[2002] } ON COLUMNS ,
{BOTTOMPERCENT([Product].[All Product].[Clothes &
Shoes].[Clothes].Children ,25,[Measures].[Total_Retail_PriceSUM] ) } ON
ROWS
FROM [OrionStar]
WHERE [Measures].[Total_Retail_PriceSUM]
Operating System and Release Information
| SAS System | SAS/ACCESS Interface to OLE DB | Microsoft Windows XP Professional | 9.1 TS1M3 SP4 | |
| Microsoft Windows XP 64-bit Edition | 9.1 TS1M3 SP4 | |
| Microsoft Windows 2000 Server | 9.1 TS1M3 SP4 | |
| Microsoft Windows 2000 Advanced Server | 9.1 TS1M3 SP4 | |
| Microsoft Windows 2000 Datacenter Server | 9.1 TS1M3 SP4 | |
| Microsoft Windows 2000 Professional | 9.1 TS1M3 SP4 | |
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
| Type: | Usage Note |
| Priority: | |
| Topic: | Third Party ==> Information Exchange ==> OLE DB (Object Linking and Embedding Database) Data Management ==> Data Sources ==> External Databases ==> OLEDB SAS Reference ==> LIBNAME Engines
|
| Date Modified: | 2008-03-07 13:56:24 |
| Date Created: | 2007-06-20 11:10:26 |