OpenDba

Syntax

OpenDbaResult OpenDba(OdId tOb, OpenDbaArg tArg)

Parameters

tOb. Moniker of the repository object that is a business application.

tArg. Operation execution parameters.

Description

The OpenDba operation opens business application.

Comments

To execute the operation, in the tOb field specify moniker of the object that is a business application, and in the tArg field specify opening parameters. The object moniker can be obtained on executing the GetObjects operation. The operation results in the opened business application instance moniker and also the metadata if an appropriate pattern was defined in the tArg.metaGet field on executing the operation. Further work with the opened task instance is executed using the GetDba and SetDba operations.

Use the CloseDba operation to close the opened business application instance.

Example

Below is the example of opening repository business application. The request contains moniker of the repository object that is a business application. The response contains moniker of opened instance.

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

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">
<OpenDba xmlns="http://www.fsight.ru/PP.SOM.Som">
<tOb xmlns="">
  <id>EMMHJHJLCLPAGOAECIKJAHOPCNJHGJDEKIODNPHMALBNJDDP!M!340435</id>
  </tOb>
  <tArg xmlns="" />
  </OpenDba>
  </s:Body>
  </s:Envelope>

SOAP response:

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

JSON request:

{
"OpenDba" :
{
"tOb" :
{
"id" : "EMMHJHJLCLPAGOAECIKJAHOPCNJHGJDEKIODNPHMALBNJDDP!M!340435"
},
"tArg" : ""
}
}

JSON response:

{
"OpenDbaResult" :
{
"id" :
{
"id" : "EMMHJHJLCLPAGOAECIKJAHOPCNJHGJDEKIODNPHMALBNJDDP!M!S!CBPKMIAKLCLPAGOAEHNHNGELNMKNCKMNEEIHLOAJKJEAJIHDJ"
}
}
}
public static OpenDbaResult OpenDba(MbId mb, string dbaId)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tOpen = new OpenDba()
{
tArg = new OpenDbaArg(),
// Create object moniker
tOb = new OdId() { id = mb.id + "!" + FindObjectById(mb, dbaId).k }
};
// Open process
var result = somClient.OpenDba(tOpen);
return result;
}

See also:

Working with Business Applications