| Previous | Next |
| MD_E_BADCOORDINATE | MD_E_INVALIDCELLRANGE |
MD_E_INVALIDAXIS
Meaning
Windows documents MD_E_INVALIDAXIS as “Axis is invalid”. In this case, the consumer references an axis identifier or position that does not exist in the current multidimensional dataset.
Evidence to collect
When recording diagnostic data involving member unique names, cube coordinates and calculated-measure expressions, use types, lengths, hashes or redacted identifiers rather than secrets or complete business data.
- Evidence 1: requested axis ordinal.
- Evidence 2: axis metadata returned for the current dataset.
- Evidence 3: query generation and UI mapping that selected the axis.
Relevant contract
OLE DB for OLAP models axes, tuples, coordinates and cells separately. A tuple identifies one member from each relevant hierarchy, a coordinate positions a cell across axes, and cell ordinals are valid only for the current dataset shape.
Investigation of this result should start with the dataset object, axis metadata, tuple construction and cellset generation used by the failing call.
Conditions that specifically lead to it
- Cause 1: the axis index exceeds the returned axis count.
- Cause 2: a slicer or filter axis is confused with a display axis.
- Cause 3: query changes removed an axis while UI state retained its index.
Diagnostic sequence
- Identify the exact failing stage: the consumer references an axis identifier or position that does not exist in the current multidimensional dataset.
Corrective actions
- Action 1: enumerate axes before addressing them.
- Action 2: map axes by current metadata rather than fixed positions.
- Action 3: reset axis-dependent state after query changes.
Practical scenario
A report assumes a second display axis after a query collapses to one; checking the axis collection avoids the invalid-axis result.
Retry and recovery
Retry rule: retry after selecting an axis reported by the current dataset.
Difference from nearby HRESULT values
MD_E_INVALIDCELLRANGE rejects cell ordinals within the cellset, while MD_E_INVALIDAXIS rejects the axis reference itself.
Official Microsoft references
Looking for a different code? Search another status or error code.