Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

getFieldsForDataSource(dataViewName, skipStoreCheck)

Updated on July 20, 2021

Obtains the columns configured on the Report Definition bound to the given data view.

Returns

The list of columns as an object.

Parameters

NameTypeDescriptionRequired
dataViewNamestringThe name of the data view through which the columns configured on the bound Report Definition are obtained.
skipStoreCheckbooleanThe flag that determines if the metadata of the given data view must be fetched from the rule store or from the browser cache.
Note:
  • The default value is false.
  • Set skipStoreCheck to true if the metadata of the given data view must be fetched from the browser cache.
  • Set skipStoreCheck to false if the metadata of the given data view must be fetched from the rule store. If the metadata is not found in the rule store, it is fetched from the browser cache.

Usage example

In this example, the API returns a Promise that resolves to a response containing the list of columns configured on the Report Definition bound to the D_MyCaseList data view.

const dataViewName = "D_MyCaseList"
PCore.getAnalyticsUtils().getFieldsForDataSource(dataViewName, false);
//The response of this API is as shown below.
  {
    "data": [ 
      { pyFieldName: "pzInsKey" }, 
      { pyFieldName: "pyID" }, 
      { pyFieldName: "columnName" } 
    ]
  }

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us