Skip to main content


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

getDataViewMetadata(dataViewName, context)

Updated on July 20, 2021

Obtains the metadata of a data view.

Returns

The metadata as a Promise.

Parameters

NameTypeDescriptionRequired
dataViewNamestringThe name of the data view whose metadata must be obtained.
contextstringThe name of the context where the API is being called.

Usage example

In this example, the API returns the metadata of the data view whose name is D_BugList.

const dataViewName = "D_BugList"
PCore.getDataApiUtils().getDataViewMetadata(dataViewName);

//The response of this API is as shown below.
{
  "classID": "PegaProjMgmt-Work-Bug",
  "className": "Bug",
  "structure": "List",
  "isQueryable": true,
  "fields": [
    {
      "description": "operator who manager assigns work to",
      "fieldID": "pyAssignedOperator",
      "fieldType": "Identifier",
      "isReadOnly": false,
      "name": "Assigned To",
      "dataType": "Identifier"
    },
    {
      "description": "This property is used to identify the work object's parent 
      Backlog and should include the pyID of that work object. In the future, 
      it will be derived from the user's data input into UserStoryIDEntry or 
      based upon the context of the creation of the item.",
      "displayAs": "pxTextInput",
      "fieldID": "BacklogID",
      "fieldType": "Text (single line)",
      "isReadOnly": false,
      "name": "Backlog ID",
      "maxLength": 32,
      "dataType": "Text"
    }
  ]   
}
  • Previous topic getData(dataViewName, payload, context, options)
  • Next topic getListCount(dataViewName, payload, context)

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