SAIL Design System guidance available for Charts
Every chart should tell a story. What does yours say? Learn how to build rich reporting dashboards that provide users with visualizations of their data. |
a!barChartConfig( primaryGrouping, secondaryGrouping, measures, sort, dataLimit, link, showIntervalsWithNoData )
Contains configuration for how to display data in a bar chart. See the Bar Chart Component page for examples on using this configuration supporting function.
See also:
Name | Keyword | Types | Description |
---|---|---|---|
Primary Grouping |
|
Grouping |
Defines the field labels to display on the axis in the chart, configured using a!grouping(). |
Secondary Grouping |
|
Grouping |
Defines the field labels to display in the stacking or grouped bars in the chart, configured using a!grouping(). |
Measures |
|
Measure |
Defines the numerical calculations for data in the chart, configured using a!measure(). If no measure is provided, a count of records shows as the measurement in the chart. |
Sort |
|
SortInfo |
Use a!sortInfo() to define a sort in ascending or descending order. Use the alias of any groupings or measures to sort by the values in the chart. Use a record field or related record field reference to sort by data that is not referenced in the chart. |
Data Limit |
|
Integer |
Maximum number of data points to display on the chart. Default: 100. Valid values: 1-5000. |
Link |
|
Any Type |
Link to execute when a user selects a data point on the chart. Use |
Show time intervals with no data |
|
Boolean |
Determines whether the axis in the chart displays date or time values that do not have a value associated with them. For example, show January, February, and March, even if February has no data. This parameter is only available when a Date, Time, or Date and Time field is used as the primary grouping. Default: false. |
a!barChartConfig()
is always used within a bar chart component.Count of <primary key field name>
.fv!selection
. This variable returns a map that contains each of the field aliases as the key and the unformatted value as the value. Since the alias is used for the key, aliases are required for each grouping and measure when using a link. See Chart Configuration Using Records for an example of how to configure a link.To use the showIntervalsWithNoData parameter, the primaryGrouping must be a Date, Time, or Date and Time field, and have a time interval set to a value other than "AUTO"
. For example:
true
when you select a time interval for your primary grouping.true
, the sort must be on the primaryGrouping field.Feature | Compatibility | Note |
---|---|---|
Portals | Compatible | |
Offline Mobile | Compatible | |
Sync-Time Custom Record Fields | Incompatible | |
Real-Time Custom Record Fields | Incompatible | |
Process Reports | Incompatible | You cannot use this function to configure a process report. |
Process Events | Incompatible | You cannot use this function to configure a process event node, such as a start event or timer event. |
The following patterns include usage of the Bar Chart Configuration.
Aggregate Data on a Date or Date and Time Field (Reports, Query Data, Grids, Records): Aggregate data, specifically the total number of employees by date.
Aggregate Data using a Filter and Display in a Chart (Reports, Charts, Query Data, Filtering, Records): Aggregate data, specifically the total number of employees for each title in the Engineering department, to display in a bar chart.
Sales by Country and Currency (Records, Reports): This pattern illustrates how to create two different charts. One chart shows sales (calculated in US dollars) by country and the currency paid. The other shows sales by currency type, comparing the number of sales paid in US dollars versus the local currency.
Sales by Region (Records, Reports, Charts): This pattern illustrates how to create a bar chart that shows sales per sales region.
Bar Chart Configuration