OpenRds

Syntax

OpenRdsResult OpenRds(OdId tOb, OpenRdsArg tArg)

Parameters

tOb. Moniker of the repository object that is an MDM dictionary.

tArg. Parameters of dictionary opening.

Description

The OpenRds operation opens an MDM dictionary and returns the context for working with dictionary data and metadata.

Comments

To execute the operation, in the tOb parameter specify moniker of the object that is an MDM dictionary, and in the tArg parameter specify patterns for the metadata to be obtained on executing the operation. Also, in the tArg parameter, specify the value of the parameters for opening the dictionary if it is parametric. If no patterns are specified in the tArg parameter, the result of the operation contains only the opened dictionary instance moniker. If the patterns are specified, the user can get obtained metadata in the meta field.

To further work with the opened dictionary instance, use the GetRds and GetRdsElements operations. Use the CloseRds operation to close the opened dictionary instance.

Example

The example of opening MDM dictionary for edit. The request contains moniker of the repository that is MDM dictionary. The response contains the opened dictionary instance moniker.

The example uses the FindObjectById function, which code is given in the Getting Object Description by Its Identifier example.

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">
<OpenRds xmlns="http://www.fsight.ru/PP.SOM.Som">
<tOb xmlns="">
  <id>S1!M!219797</id>
  </tOb>
<tArg xmlns="">
<args>
  <bind>true</bind>
  <openForEdit>true</openForEdit>
  </args>
  </tArg>
  </OpenRds>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<OpenRdsResult 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">
<id xmlns="">
  <id>S1!M!S!N2</id>
  </id>
  </OpenRdsResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
"OpenRds" :
{
"tOb" :
{
"id" : "S1!M!219797"
},
"tArg" :
{
"args" :
{
"bind" : "true",
"openForEdit" : "true"
}
}
}
}

JSON response:

{
"OpenRdsResult" :
{
"id" :
{
"id" : "S1!M!S!N2"
}
}
}
public static OpenRdsResult OpenRDSDimension(MbId mb, string id)
{
var somClient = new SomPortTypeClient(); //Proxy object for operation execution
//Operation execution parameters
var tOpen = new OpenRds()
{
tArg = new OpenRdsArg()
{
args = new RdsOpenArgs()
{
bind = true,
openForEdit = true
}
},
tOb = new OdId() { id = mb.id + "!" + FindObjectById(mb, id).k }
};
//Open MDM dictionary
var tResult = somClient.OpenRds(tOpen);
return tResult;
}

See also:

Working with MDM Dictionaries