DashboardRelationshipsAdd

Syntax

ItEntityEx DashboardRelationshipsAdd(string mon)

Parameters

mon. Moniker for working with the relations used in calculated fact formulas.

Description

The DashboardRelationshipsAdd operation creates a new relation for calculated fact formulas.

Comments

To execute the operation, in the mon field specify moniker of opened information panel instance with the !Sources!data source key!Relationships postfix to work with relations. The moniker can be obtained on executing the OpenDashboard operation.

The operation results in the general metadata of the created relation.

Further work with the relation is executed using the GetDashboardRelationship and SetDashboardRelationship operations. To delete relation, use the DashboardRelationshipsDelete operation.

Example

Below is the example of creating a new relation used in calculated fact formulas of information panel data source. The request contains the moniker for working with relations. The response contains basic information about the created relation.

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">
<DashboardRelationshipsAdd xmlns="http://www.fsight.ru/PP.SOM.Som">
  <mon xmlns="">LKACHLFPHPFFGOAEFAJMIHOHCKLEPLKEEIENANDBMODOBJMH!M!S!PHOONDMFPHPFFGOAEGILOHDKLDDEDFAAEEJAAJAMKHGKPJBCK!Sources!1!Relationships</mon>
  </DashboardRelationshipsAdd>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<DashboardRelationshipsAddResult 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">
  <k xmlns="">4</k>
  <id xmlns="">ITEM</id>
  <n xmlns="">Relation</n>
  </DashboardRelationshipsAddResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
"DashboardRelationshipsAdd" :
{
"mon" : "LKACHLFPHPFFGOAEFAJMIHOHCKLEPLKEEIENANDBMODOBJMH!M!S!PHOONDMFPHPFFGOAEGILOHDKLDDEDFAAEEJAAJAMKHGKPJBCK!Sources!1!Relationships"
}
}

JSON response:

{
"DashboardRelationshipsAddResult" :
{
"k" : "4",
"id" : "ITEM",
"n" : "Relation"
}
}
public static ItEntityEx DashboardRelationshipsAdd(string moniker, uint sourceKey)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tAdd = new DashboardRelationshipsAdd()
{
// Moniker for working with relations
mon = moniker + "!Sources!" + sourceKey + "!Relationships"
};
// Create a relation
var result = somClient.DashboardRelationshipsAdd(tAdd);
return result;
}

See also:

Working with Information Panels