Skip To Content

Select data

Data is at the core of most apps you create with Experience Builder. Many widgets are data-driven, and the builder provides unified data management. Widgets consuming the same data can be connected in your app. For example, you can synchronize record selections across multiple widgets and apply the same filter across widgets that are connected to the same data.

When you add data to an app in Experience Builder, it’s a specific instance of a data source connection. The benefits of this include the following:

  • Updates to the original data source are synchronized in the apps you build.
  • You can add the same data source multiple times. The connections become independent data in Experience Builder. Most of the data processing doesn’t affect other data processing (such as filtering and sorting), with the exception of updates that are made to the original data source (such as editing features and updating attributes).

Manage data

All the data you add to the app is listed in the Data panel of the builder workspace. You can manage the app’s data here and review related information, such as how many and which widgets are connected to the data and to which fields, when applicable.

Add data to the app

When adding data to your app, you can select web maps, web scenes, and layers stored as content items in ArcGIS, including the following:

You can browse and search for these data sources in your content, your groups, your organization, and content that’s shared publicly, including ArcGIS Living Atlas of the World. Layers from feature, scene, or map service URLs are also supported. In addition, when you add web maps and web scenes to your app, you can use their supported layers as a data source for widgets.

Note:

  • When you add a web map or web scene as a data source, widgets can connect to its supported layers, such as tables, map image layers, tile layers, and group layers. Unsupported layer types aren't available in widget settings and don't appear in the details tab of the Data panel.
  • Web maps and web scenes created with JSAPI 3.x that cannot be opened in Map Viewer or Scene Viewer cannot be used as data sources. (If you add one of these items, it won’t be available to select and appears in the Data panel as an error card.)

You can add data to an app in two ways:

  • Before adding any widgets, click the Add data button in the Data panel to add data that will be used in the app. All data types supported in Experience Builder are listed in the Add data window.
  • If you don’t add data before adding widgets, you can also add data when configuring a widget by clicking Add data at the bottom of the Select data pane. Only the data type supported by the widget is available to add. The data you add when configuring a widget also appears in the Data panel and is available to select when configuring other widgets.
Note:

You can choose to hide some sub-layers in a service, a group layer, or a web map or web scene when you add data. Or you can hide them under the detail panel of the service, group, web map, or web scene. The hidden layers won’t be available in the select data list when you configure widgets. You can only hide layers that aren't used yet.

Remove data

You can remove a data source using the Remove option on item cards in the Data panel. The data contained within the data source will be removed as well. When you remove data here, it is no longer available for widget configuration. If you remove data that’s already used by widgets, the app will no longer display information from that data, and all widgets connected to that data will be affected. You can delete the affected widgets when you delete the data, or you can reconfigure the widget settings by connecting other data later.

Data details and data views

The Data panel displays item cards with the item names for data that you add to the app. Labels with icons help you differentiate between data types. You can view additional details by clicking the link to open the item page for the original data source. You can change the name that appears on the item cards to something more relevant to your app (the source data is unchanged). Each card indicates the number of related widgets and layers in a map or scene. Clicking a data card opens a pane with more data details.

  • For web maps, web scenes, services, and group layers, you can view the following details:
    • Layers tab—Layers that the data source contains. The layers are divided into two groups: In use shows layers that are selected in widget settings, and Others shows layers not yet connected to a widget. You can hide an unused layer so it won’t appear in the select data list when you configure a widget. Click the layer card to open a details pane.
    • Widgets tab—Widgets that use the entire map, scene, service, or group layer directly. Widgets that only use specified layers under the data aren’t listed here; they’re listed under the corresponding layer instead.
  • For single layers (including those without sub-layers), you have the following setting options and details:
    • Data settings—Set filters, sort fields, and record limitations for the data. The settings here affect all its data views.
    • Refresh settings—If the auto refresh is turned off, the data will get refreshed only when you refresh the app or the builder. Turn on the auto refresh to allow refreshing the data and getting the latest features based on a certain time interval. You can set a custom time interval or if the data comes from a web map, you can choose to honor the layer’s settings.
    • Fields tab—Fields used by widgets.
    • Widgets tab—Widgets that use the layer in their settings.
    • Data views tab—Create data views of supported feature layers and scene layers by adding filter and sort criteria to control what appears in connected widgets.
      • You can add multiple data views with different filters, sort fields, and record limitations. These settings only take effect within the view and won’t affect other data views or the source data.
      • For each layer, there are two built-in views. The Default view represents the data. The Selected features view represents the collection of selected features in the layer. The selected state of a feature is synchronized through all views.
      • The selected features view can be used to display an interaction result; for example, clicking a feature to show its attributes. But if there is no selection, by default, the attribute name is displayed instead. To avoid this, you can check on the View for empty selection option and configure a view to display the information of features in that view when there's no selected feature. Note that the features in the configured view won't be selected automatically.
      • If a widget is added into a List widget and is connected to the same data view, an Auto-populated view is available in dynamic content settings. This view only contains one feature that the list generates for each item in it.
      Note:

      The data and its views have a 1:M relationship and the effect is one-way. The data settings will affect all views, but the view settings will not affect each other or the data. For more information about the relationship between data and its views, see the View (SQL) wiki article.

Use data

Any data you add to an app, regardless of how you add it, is available to all supported widgets in that app. A data source used by one widget can be used by others. Record selection is synchronized throughout the app. In addition, data processing on the default data view (filter, sort, and record limitations) affects all widgets that consume the data or its views. Data processing on a specific data view only affects widgets that use the same data view.

Note:

When displaying a web map or web scene in a Map widget, a new web map or web scene view is created automatically, and this view is only used in the current widget. Thus, data processing within the Map widget won't affect widgets using the same data source or its contained layers. But the Map is affected by data processing on the default view.

The configuration panel for each widget includes a standard setting to connect to data. When you click Select data, a pane appears that lists the data in the app that the widgets support (hidden data is not listed). You can select data from the list or add more data to the app. Some widgets support multiple data sources, so you can select more than one item in the list. If a widget can only be connected to one data source, click the existing data card to open the Select data pane where you can clear the selection and select another item.

Once the data is selected and it contains data views, you can choose one or more views in the drop-down list, based on how many data sources the widget supports. The Default view is selected by default. You can also edit an existing view or create a new view for the widget. The created view will be available for other widget settings.

The table below lists the widgets that you can connect to data and the supported data types for each.

WidgetSupported data type*Supported data number

Branch Version Management

Feature service, map service (must be registered as versioned)

1 or multiple

Button**

Feature layer, scene layer

0 or 1

Embed**

Feature layer, scene layer

0 or 1

Feature Info

Feature layer

1

Filter

Feature layer, scene layer

1 for each filter

Image**

Feature layer, scene layer

0 or 1

List

Feature layer, scene layer

1

Map

Web map, web scene

1 or 2

Map layers

Web map, web scene

0 or 1

Table

Feature layer

1 for each sheet

Text**

Feature layer, scene layer

0 or multiple

*For a specific list of supported item types, see Add data to the app.

**Image, Text, Button, and Embed widgets are static by default. To display information from the data, turn on the Connect to data setting and specify the parameters with attributes, statistics, or expressions. For more information, see Dynamic content.

Dynamic content

Several widgets have settings for which you can use or display dynamic information from a connected data source. Examples include an attribute value of a specified feature, a statistic result of features meeting certain conditions, or an expression mixed with static strings, dynamic values, and computations.

Attribute

Get the attribute value of a feature in the specified data view using one of the following views:

  • The views you set in the widget’s data source setting.
  • The Selected features view of the original data layer. This view allows you to display the interaction results such as displaying the selected feature’s attributes.
  • The Auto-populated view if the widget is within a List widget (such as text, image, or button) and has the same data view as the List. This view contains only one feature that the list item represents.

If the view you choose contains multiple features, the attribute value of the first feature is returned (based on the sort settings in the data view).

Statistics

Get the statistics results of the feature set defined by the specified data view.

Results could be the maximum, minimum, average, or sum value of a numeric field, or the feature count of the feature set.

Expression

The expression editor allows you to input text (format: “text”), numbers, field variables (format: {fieldname}) and functions including AVERAGE({fieldname}), COUNT, SUM({fieldname}), MAX({fieldname}), and MIN({fieldname}). Each part is concatenated with a plus sign (+). The expression returns the result of string concatenation and number calculation. For example, if you input 1+1, it returns 2(number), but if you input 1 + “1”, it returns “11”(string).

As you type, suggestions are offered that you can click to insert. Also, you can insert a field variable or a function by clicking the field names or function names listed under the input box.

Data under the Fields tab allows you to set which data view the field variable represents. If a field variable is added as an independent part in the expression, the attribute value for that field is returned from the first feature in the specified data view.

If a numeric field variable is used within a function; for example, AVG({fieldname}), the function returns the statistic result of the data view for that field.