SetPivotHeaderFilterMetaData

Syntax

PivotHeaderFilter SetPivotHeaderFilterMetaData(string mon, PivotHeaderFilter tArg)

Parameters

mon. Moniker for working with data slice header filter.

tArg. Parameters for changing filtering settings.

Description

The SetPivotHeaderFilterMetaData operation changes filtering settings for data slice header.

Comments

To execute the operation, in the mon field specify regular report instance moniker with the !DataArea!DataSources!<data source key>!DataSourceSlices!<slice key>!Pivot! postfix. This moniker should also be appended with one of the following values:

The moniker can be obtained on executing the OpenPrxMeta operation.

In the tArg field set filtering parameters that should be applied. The operation returns True if changes are applied successfully.

Example

Below is the example of changing filtering settings in data slice columns header. The request contains moniker for working with header filtering settings and filtering parameters to be changed. The response indicates whether changes are applied successfully.

SOAP request:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<SetPivotHeaderFilterMetaData xmlns="http://www.fsight.ru/PP.SOM.Som">
  <mon xmlns="">S1!M!S!P1!DataArea!DataSources!1!DataSourceSlices!1!Pivot!TopHeader!HeaderSettings!Filter</mon>
<tArg xmlns="">
  <enabled>true</enabled>
  <suppressEmptyCells>true</suppressEmptyCells>
  </tArg>
  </SetPivotHeaderFilterMetaData>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
  <SetPivotHeaderFilterMetaDataResult xmlns="http://www.fsight.ru/PP.SOM.Som" xmlns:q1="http://www.fsight.ru/PP.SOM.Som" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">1</SetPivotHeaderFilterMetaDataResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
"SetPivotHeaderFilterMetaData" :
{
"mon" : "S1!M!S!P1!DataArea!DataSources!1!DataSourceSlices!1!Pivot!TopHeader!HeaderSettings!Filter",
"tArg" :
{
"enabled" : "true",
"suppressEmptyCells" : "true"
}
}
}

JSON response:

{
"SetPivotHeaderFilterMetaDataResult" : "1"
}
public static bool SetPivotHeaderFilter(string moniker, ulong dataSourceKey, ulong sliceKey)
{
var somClient = new SomPortTypeClient(); //Proxy object for operation execution
//Operation execution parameters
var tSet = new SetPivotHeaderFilterMetaData()
{
tArg = new PivotHeaderFilter()
{
enabled = true,
suppressEmptyCells = true,
},
mon = moniker + "!DataArea!DataSources!" + dataSourceKey.ToString() + "!DataSourceSlices!" + sliceKey.ToString() + "!Pivot!TopHeader!HeaderSettings!Filter"
};
//Change header filter settings
var result = somClient.SetPivotHeaderFilterMetaData(tSet);
return result;
}

See also:

Working with Regular Reports