## Excel CUBESETCOUNT Function

The CUBESETCOUNT function returns the number of items in a set.

#### Syntax

=CUBESETCOUNT(set)

#### Arguments

• set (required): A text string of an Excel expression that evaluates to a set as defined by the CUBESET function. Alternatively, set can be the CUBESET function, or a reference to a cell that contains the CUBESET function.

#### Return Value

The CUBESETCOUNT function returns an integer.

#### Function Notes

• The #GETTING_DATA… message is displayed while the data is being retrieved.

#### Example

I have a table here named “sales2021” which includes the information of sales and rating of different products of 2 categories across the year 2021. I’ve already used the CUBESET function in a report table to get the total sales of certain products/months for specific months/products. To use the CUBESETCOUNT function to get the number of items in the sets in cells G12 and L5 where contain the CUBESET function, please copy or enter the formulas below in cells J14 and J15 respectively, and press Enter to get the results:

=CUBESETCOUNT(G12)

=CUBESETCOUNT(L5)

√ Note: Instead of the cell reference, you can copy the CUBESET function as the set argument:

=CUBESETCOUNT(CUBESET("ThisWorkbookDataModel",(\$G\$8,\$G\$6,\$G\$7,\$G\$10,\$G\$11,\$G\$9),"Grand Total"))

#### Related functions

Excel CUBESET Function

The CUBESET function defines a calculated set of members or tuples by sending a set expression to the cube on the server. The function can extract all unique values from a set expression, and it offers options for sorting.

Excel CUBEVALUE Function

The CUBEVALUE function returns an aggregated value from a cube filtered by multiple member_expression arguments.

Excel CUBEMEMBER Function

The CUBEMEMBER function retrieves a member or tuple from a cube if it exists. Otherwise, a #N/A error value will be returned.

Excel CUBEKPIMEMBER Function

The CUBEKPIMEMBER function returns the key performance indicator (KPI) property and displays the KPI name in the cell.

### The Best Office Productivity Tools

#### Kutools for Excel - Helps You To Stand Out From Crowd

 🤖 Kutools AI Aide: Revolutionize data analysis based on: Intelligent Execution   |  Generate Code  |  Create Custom Formulas  |  Analyze Data and Generate Charts  |  Invoke Kutools Functions… Popular Features: Find, Highlight or Identify Duplicates  |  Delete Blank Rows  |  Combine Columns or Cells without Losing Data  |  Round without Formula ... Super VLookup: Multiple Criteria  |  Multiple Value  |  Across Multi-Sheets  |  Fuzzy Lookup... Adv. Drop-down List: Easy Drop Down List  |  Dependent Drop Down List  |  Multi-select Drop Down List... Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  |  Compare Columns to Select Same & Different Cells ... Featured Features: Grid Focus  |  Design View  |  Big Formula Bar  |  Workbook & Sheet Manager | Resource Library (Auto Text)  |  Date Picker  |  Combine Worksheets  |  Encrypt/Decrypt Cells  |  Send Emails by List  |  Super Filter  |  Special Filter (filter bold/italic/strikethrough...) ... Top 15 Toolsets:  12 Text Tools (Add Text, Remove Characters ...)  |  50+ Chart Types (Gantt Chart ...)  |  40+ Practical Formulas (Calculate age based on birthday ...)  |  19 Insertion Tools (Insert QR Code, Insert Picture from Path ...)  |  12 Conversion Tools (Numbers to Words, Currency Conversion ...)  |  7 Merge & Split Tools (Advanced Combine Rows, Split Excel Cells ...)  |  ... and more

Kutools for Excel Boasts Over 300 Features, Ensuring That What You Need is Just A Click Away...

#### Office Tab - Enable Tabbed Reading and Editing in Microsoft Office (include Excel)

• One second to switch between dozens of open documents!
• Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
• Increases your productivity by 50% when viewing and editing multiple documents.
• Brings Efficient Tabs to Office (include Excel), Just Like Chrome, Edge and Firefox.