Pies charts show the proportions that make up a whole.

You can use a pie chart to show things like open incidents by priority. For example, suppose that an organization has a policy that critical incidents can never exceed 40% of all open incidents. Given that there are always open incidents of various priority levels, you can quickly see with a pie chart when incident counts exceed acceptable ranges. This figure shows that 14.61% of the open incidents are critical.
Note: This topic refers to Reporting in the Core UI. If your instance is migrated to Platform Analytics experience, see Create a pie or donut visualization in the Visualization Designer.

This data visualization is supported on the mobile platform. For more information, see Pie charts for mobile and Mobile dashboard preview.

Figure 1. Pie chart
Pie chart

Create a pie chart

Create a pie chart to compare the size of individual categories to the whole.

Before you begin

Role required: itil, report_user, report_group, report_global, report_admin, or admin. To create a meaningful report, you must have the right to access the data you want to report on.

Procedure

  1. Perform one of the following actions:
    • On an upgraded instance that has not been fully migrated to Platform Analytics, navigate to All > Reports > Create New.
    • On a new instance or one that has been fully migrated to Platform Analytics, navigate to All > Platform Analytics Administration > Usage and governance > Reports and select New.
  2. On the Data tab, give the report a name that reflects the information being grouped.
  3. Select the applicable source for the report.
    OptionDescription
    Data source Also called a report source, a data source is a table with filters applied to provide a single source of information for all users. For more information, see Report sources.
    Note: If you select a data source used by existing reports, a notification prompts you to view them.
    Table The raw data from a table with no filters applied. When you select a table, its short description appears below the table name.

    For trend reporting, you can also select a remote table, which aggregates, in memory, data retrieved from an external source. Then select a Trend by field option to aggregate its data. To learn more about remote tables, see Retrieving external data using remote tables and scripts

    External import Choose an existing imported report source, or select the Upload icon (Upload icon) to import a new file. See Create a report from an imported Microsoft Excel document.
    MetricBase MetricBase enables you to collect, retain, analyze, and visualize custom time series data on the ServiceNow AI Platform. For more information, see MetricBase.
  4. Select Next.
  5. On the Type tab, enter Pie in the filter, select the report type, and click Next.

    The application shows a preliminary version of the report. To view the updated report at any time, select Run.

  6. On the Configure tab, fill in the following fields and select Next.
    Table 1. Configure tab
    Field Description
    Group by Group report data using the values of this field. For example, in an incident report grouped by Assignment group, all incidents that belong to Software, Service Desk, and Network are placed in separate groups. To group by fields on extended tables, see How to report on extended tables. Select the info icon () for a description of the selected field.

    Configured function fields appear in this list after you save the report.

    Note:
    • It is not possible to group or stack reports by the Tags field, or by certain MySQL database field types, such as MEDIUMTEXT. For more information, see Database field type.
    • Grouping or stacking by Variables or Questions fields is not supported for reports based on database views.
    Additional group by Extra fields to group the report by. When you select Additional group by fields or function fields, the report includes a control at the bottom that allows you to group the report by any one of the additional fields. To group by fields on extended tables as well, see How to report on extended tables. Click the info icon () for descriptions of the selected fields
    Configured function fields appear in this list after you save the report.
    Note:
    • You can see choices in the Additional group by list that do not appear in the main Group by list. The report does not support grouping or stacking by the extra fields you see. Unlike the main Group by choices, the Additional group by fields are not filtered. If you select an unsupported field, it has no effect.
    • The limitations listed for the main Group by field also apply to the Additional group by field.

    For more information, see Add an additional group by or stack by.

    Display data table Select this option to show report data in a list below the report. The list appears on dashboards where the report is added.

    All report visualizations show the report data when the glide.ui.section508 system property is set to true. The glide.ui.section508 property overrides the Display data table field.

    Configure function field Configure fields based on calculation of multiple inputs including arithmetic functions. For more information, see Report on function fields. Function field results are calculated when the report is run. You can use the results for aggregations and grouping. You have to save the report before you can configure function fields.

    Configured function fields appear in the Group by and Additional group by lists after you save the report.

    Aggregation Mathematical calculation to perform on the data. The default is Count, which shows the number of records selected.

    To show only unique records, select Count Distinct.

    Select Average, Sum, or Count Distinct, to show a list of fields from the selected Table. Select a field to Aggregate by from this list.

    If you group the report by a field and select an Average aggregate, you get the average of each group. If a Total value is shown, it is the average of these group averages, not of the individual field values.

    Select Minimum or Maximum to show the maximum or minimum value for each segment of the report.

    For more information on aggregation options, see Aggregation in reporting.

    If you choose Average,Sum, Count Distinct, Minimum, or Maximum, you may be able to aggregate on fields from extended tables. See How to report on extended tables.

    For information about aggregating on FX currency values, see FX Currency values in reporting.

    Set Value Formatting

    Enables you to configure how to show numerical values in reports, including decimal precision, rounding, minimum and maximum duration units, and abbreviations for duration units. See Value formatting in reports.

    Note: Decimal precision does not work on currency fields.
    Max number of groups Maximum number of groups that the Group by condition returns. The groups with highest values are shown first. Any groups beyond the limit are combined into the single group Other.

    If you select Show all, all groups up to a limit of 50 are displayed. The rest of the results are grouped as Other.

    Show Other Check box to include the Other group in the report. The Other group contains data for all groups that exceed the number specified in Max number of groups.
  7. (Optional) Configure the sort order of the applicable fields in the report (column, row, Group by, Stack by or Trend by depending on the report type).
    Select the filter icon () and choose Add Sort.
    1. In the Sorting Order list, choose the field you want to sort on and then choose a-z or z-a for alphabetical order or reverse alphabetical order.

      The list contains all possible fields from the report's source and fields on extended, or related, tables. The only effective values, however, are the fields chosen for the current report (column, row, Group by, Stack by, or Trend by depending on the report type).

      Note: On fields from dot-walked (extended) tables, you can only sort on date fields.
    2. Select the sort plus icon () to configure additional sorting order conditions. (Select the sort minus icon ( ) to delete configured sorting order conditions.)
    3. Select Save.

    For fields of the type Choice list, sort order is not determined alphabetically based on Label, it is sorted based on the Value of the choice field. For multi-level pivot table and heatmap reports, sort order is determined by the sequence of the choices in the list.

    Report sorted by priority choice list
  8. (Optional) To limit the information displayed in the report, select the filter icon () and specify conditions to filter the report data.
    To learn how to construct conditions, see Condition builder.
    Note: In aggregated and list reports, language-dependent filter conditions may return zero results on localized instances.
  9. On the Style tab, fill in the fields as appropriate to configure the appearance of the report.
  10. Select Save to continue editing the visualization, or Save and close to return to the Analytics Center main screen.

What to do next

  • Select the Report info icon () and add a description of the report.
  • Select the sharing icon () to open the Sharing menu. On this menu, you can add the report to a dashboard, export the report to PDF, publish the report to the web, and set visibility and schedules.

Pie chart style options

Change the look of your pie chart.

When you create or edit a report, click the Style tab for options to configure the look of your report. The options are organized under two or more of the following tabs: General, Title, Legend, and Axis. To see how the report looks with the changed settings, click Save.

Table 2. Chart style options
Field Description
General
Chart color Source of the colors used in the report. Select from the following:
  • Use color palette: Select a color palette from the predefined system color palettes.
  • Use several colors: Define a custom set of Colors using hex codes. You can add any number of colors.
  • Use chart colors: Use the colors defined in Reports > Chart Colors.
Set palette Color palette used in the report. This field appears when you select Use color palette from the Chart color list. The palettes are defined in the Chart Color Scheme [pa_chart_color_schemes] table.
Colors Colors used in the report. This field displays when you select Use several colors from the Chart color list. Enter a comma-separated list of hexadecimal color codes. These colors are independent of the predefined system colors that color palettes and the chart colors use.
Note: It is not possible to use transparency hex values.
Display data labels Check box to display the value for each slice.
Custom chart size Check box to specify the width and height of the report in pixels.
Note: The chart size is ignored when you export the report to PDF. In PDFs, the full page width is used to show the chart.
Chart width Width of the report in pixels. The default value is 600.

This field is available when Custom chart size is selected.

Chart height Height of the report in pixels. The default value is 450.

This field appears when Custom chart size is selected.

Chart size Chart size. This field is available when Custom chart size is cleared. Options are Small, Medium, and Large.
Note: The chart size is ignored when you export the report to PDF. In PDFs, the full page width is used to show the chart.
Drilldown view List view to show when a user selects a segment of a report for which no drilldown report type is specified. This view is also used when the user reaches the lowest drilldown level of a report. See Configure the list layout . If you specify a Report drilldown, Drilldown view is ignored.

For more information, see Define a report drilldown.

Decimal precision Number of decimal places to show. You can show from zero to four decimal places. Default value: 2. To change the default value, create the system property glide.chart.decimal.precision and specify the value. This option is available for Average aggregations.
Note: Percentage labels do not change accordingly with the decimal precision specified.
Decimal precision - Donut report
Title
Show chart title When the chart title is shown for the report.
  • Never: Never show the chart title.
  • Report only: Shows the chart title on reports.
  • Always: Shows the chart title on reports, dashboards, and landing pages.
Chart title The chart title has a maximum length of 40 characters. If no title is entered, the report name is used for the title. This field appears when Report only or Always is selected from the Show chart title list.
Size of the chart title Size of the chart title in pixels. This field appears when Report only or Always is selected from the Show chart title list.
Chart title color Color of the chart title. This field appears when Report only or Always is selected from the Show chart title list.
Custom chart title position Check box to specify X and Y coordinates for the position of the chart title. This field appears when Report only or Always is selected from the Show chart title list.
Title horizontal alignment How the chart title is aligned horizontally. This field is available when the Custom chart title position option is cleared.
Title vertical alignment How the chart title is aligned vertically. This field appears when Custom chart title position is cleared.
Chart title X position Number of pixels to adjust the chart title position right or left. By default the title appears at the center top of the chart. To move the chart title to the right, enter a positive value. To move the title to the left, enter a negative value.

This field appears only when Custom chart title position is selected.

Chart title Y position Number of pixels to adjust the chart title position up or down. By default the title appears at the center top of the chart. To move up the chart title, enter a positive value. To move the chart title down, enter a negative value.

This field appears only when Custom chart title position is selected.

Legend
Show legend Check box to show a chart legend. This check box appears when a Group by field is selected on the report form.

Legends are truncated by default. To adjust truncation lengths, configure the properties glide.chart.label.legend.truncate_to and glide.chart.label.legend.truncate_to.large. For more information, see Reporting properties.

Legend horizontal alignment How the legend is aligned horizontally. This field appears when Show legend is selected.
Legend vertical alignment How the legend is aligned vertically. This field appears when Show legend is selected.
Show legend border Check box to show a border around the legend. This check box appears when Show legend is selected.
Left align legend text Check box to left-align the legend text when the report is viewed in a browser. By default, the legend text is centered. When the report is exported to PDF, PNG, or JPG, the legend remains centered. This check box appears when Show legend is selected.