Newer Version Available

This content describes an older version of this product. View Latest

Extended Metadata (XMD) Overview

Extended metadata (XMD) allows you to customize the formatting of many dashboard elements in Analytics Cloud.

If you modify the XMD for a dataset, every UI visualization that uses the dataset uses the new formatting. The XMD file is in JSON format and can be uploaded to Analytics Cloud. You can control the following:

  • The formatting of measures
  • Display labels for dimensions and measures
  • The grouping of dimensions of measures
  • Colors of specific fields
  • Default columns to be displayed for a values table
  • The hiding of dimensions and measures in the user interface
  • Custom menus that let users take advantage of actions on Salesforce objects and follow links to records in Salesforce and external websites
  • Mapping of Salesforce org IDs to their URLs so that a link to a Salesforce record from a multiorg datasets resolves to the correct org instance for that record

Extended Metadata Example

The following example illustrates the format of the XMD file.

Every dimension and measure that’s referenced must be valid. Otherwise the reference is ignored.

Note

1{
2    "formats": {
3        "measures": {
4            "Amount": [
5                "$#,##0.00",
6                1
7            ]
8        }
9    },
10    "hide_dimensions": [
11         "Owner-Email"
12    ],
13    "labels": {
14        "dimensions": {
15            "CloseDate": "Close Date GMT",
16            "CloseDate_Day": "Close Date Day",
17            "CloseDate_Month": "Close Date Month",
18            "CloseDate_Quarter": "Close Date Quarter",
19            "CloseDate_Week": "Close Date Week",
20            "CloseDate_Year": "Close Date Year",
21            "CreatedDate": "Created Date GMT",
22            "CreatedDate_Day": "Created Date Day",
23            "CreatedDate_Month": "Created Date Month",
24            "CreatedDate_Quarter": "Created Date Quarter",
25            "CreatedDate_Week": "Created Date Week",
26            "CreatedDate_Year": "Created Date Year",
27            "Id": "Id",
28            "OpportunityId": "Opportunity Id",
29            "StageName": "Opp Stage"
30        },
31        "measures": {
32            "Amount": "Total Amount"
33        },
34        "measure_filters": {
35            "Amount": "Amount",
36		          "*": "OpportunityId"
37        },
38        "keys": {
39            "IsClosed": {
40                "true": "Closed",
41                "false": "Open"
42            },
43            "Outcome": {
44                "true": "Won",
45                "false": "Lost"
46            },
47            "Region": {
48                "EU": "Europe",
49                "AP": "Asia Pacific",
50                "US": "United States"
51            }
52        }
53    },
54    "types": {
55        "Close Date GMT": {
56            "dims": {
57                "day": "CloseDate_Day",
58                "fullField": "CloseDate",
59                "month": "CloseDate_Month",
60                "quarter": "CloseDate_Quarter",
61                "week": "CloseDate_Week",
62                "year": "CloseDate_Year"
63            },
64            "meas": {
65                "epoch_day": "CloseDate_day_epoch",
66                "epoch_second": "CloseDate_sec_epoch"
67            },
68            "type": "date"
69        },
70        "Created Date GMT": {
71            "dims": {
72                "day": "CreatedDate_Day",
73                "fullField": "CreatedDate",
74                "month": "CreatedDate_Month",
75                "quarter": "CreatedDate_Quarter",
76                "week": "CreatedDate_Week",
77                "year": "CreatedDate_Year"
78            },
79            "meas": {
80                "epoch_day": "CreatedDate_day_epoch",
81                "epoch_second": "CreatedDate_sec_epoch"
82            },
83            "type": "date"
84        }
85    },
86    "colors": {
87        "StageName": {
88            "5 - Closed-Won": "#4f4",
89		          "5 - Closed-Lost": "#f44"
90	  },
91	  "Region": {
92	      "AP": "#fc6",
93	     	"EU": "#48f",
94		     "US": "#f88"
95	  }
96    },
97    "values_query_columns": [
98        "Id",
99        "OpportunityId",
100        "StageName"
101      ]
102}