INFO.GENERALSEGMENTMAPSEGMENTMETADATASTORAGES DAX Function (Information)
Returns a list of all general segment map segment metadata storages in the current model with columns matching the schema rowset for general segment map segment metadata storage objects.
Syntax
| Parameter | Attributes | Description |
|---|---|---|
| RestrictionName | Optional Repeatable |
Restriction name. |
| RestrictionValue | Optional Repeatable |
Restriction value. |
Return values
A table with one row for each segment of a general segment map storage in the model. The columns match the TMSCHEMA_GENERAL_SEGMENT_MAP_SEGMENT_METADATA_STORAGES DMV.
| Field | Type |
|---|---|
| ID | Integer |
| SegmentMapStorageID | Integer |
| RecordCount | Integer |
| Ordinal | Integer |
Remarks
Corresponds to the TMSCHEMA_GENERAL_SEGMENT_MAP_SEGMENT_METADATA_STORAGES data management view (DMV).
As all the INFO functions, it cannot be used in calculated tables and calculated columns.
Use this function in a DAX query. Without arguments, the function returns all the rows. To filter the rows, pass pairs of arguments: the name of a restriction and its value, both as text. If you use more than one pair, a row must match all of them. The number of arguments must be even, and an unknown restriction name returns an error. The restriction name is not case sensitive. The restriction name is the name of a column in the result. All the columns are valid restriction names. For example, INFO.GENERALSEGMENTMAPSEGMENTMETADATASTORAGES ( “SegmentMapStorageID”, “411” ) returns the segments of one segment map storage.
According to Microsoft documentation, the function returns one row for each segment of a general segment map storage. SegmentMapStorageID is the ID of the segment map storage in INFO.SEGMENTMAPSTORAGES, RecordCount is the number of records in the segment and Ordinal is the position of the segment. In the test model, the function returns an empty table, also if INFO.SEGMENTMAPSTORAGES has 155 rows. The example counts the general segments for each type of segment map storage.
According to Microsoft documentation, only users with write permission on the semantic model can run this function, and it does not work in a live connection to a model in Power BI Desktop.
Examples
-- INFO.GENERALSEGMENTMAPSEGMENTMETADATASTORAGES returns one row for each segment of a general segment map storage.
-- The query counts these segments for each type of segment map storage in INFO.SEGMENTMAPSTORAGES.
-- The test model has no rows in the function, so the counts are 0.
EVALUATE
VAR SegmentMaps =
SELECTCOLUMNS ( INFO.SEGMENTMAPSTORAGES (), "ID", [ID], "Type", [Type], "RecordCount", [RecordCount] )
VAR Segments =
SELECTCOLUMNS (
INFO.GENERALSEGMENTMAPSEGMENTMETADATASTORAGES (),
"SegmentMapStorageID", [SegmentMapStorageID]
)
VAR Result =
ADDCOLUMNS (
GROUPBY (
SegmentMaps,
[Type],
"Segment map storages", COUNTX ( CURRENTGROUP (), 1 )
),
"General segments",
VAR CurrentType = [Type]
VAR IDs = SELECTCOLUMNS ( FILTER ( SegmentMaps, [Type] = CurrentType ), "ID", [ID] )
RETURN
COUNTROWS ( NATURALINNERJOIN ( SELECTCOLUMNS ( Segments, "ID", [SegmentMapStorageID] ), IDs ) ) + 0
)
RETURN
Result
ORDER BY [Type]
| Type | Segment map storages | General segments |
|---|---|---|
| 2 | 134 | 0 |
| 3 | 21 | 0 |
Last update: Dec 4, 2026 » Contribute » Show contributors
Contributors: Alberto Ferrari, Marco Russo
Microsoft documentation: https://learn.microsoft.com/en-us/dax/info-generalsegmentmapsegmentmetadatastorages-function-dax