edmiRemoteGetAttrDefinitionBN
EdmiError edmiRemoteGetAttrDefinitionBN(SdaiServerContext serverContextId, SdaiString schemaName, SdaiString entityName, SdaiString attributeName, SdaiAttr *attributeId, SdaiInvocationId *edmiInvocationId);
Returns a numeric attributeID that uniquely identifies an attribute definition instance in the remote EDMdatabase. The attribute is uniquely specified by the names of the Express Schema, the entity and the attribute it self. If the attribute name is not unique within the entity, it must be qualified by the name of the entity from which it is inherited. The returned attributeID will not change throughout the lifetime of its attribute definition instance in the EDMdatabase. It may be used to identify the attribute in subsequent EDMinterface operations.
Arguments
Type | Name | Comment |
 SdaiServerContext | serverContextId | Context identification, from edmiDefineServerContext |
 SdaiString | schemaName | The name of the Express Schema in the remote EDMdatabase in which the attribute is defined. |
 SdaiString | entityName | The name of the entity in which the attribute is defined. |
 SdaiString | attributeName | The name of the attribute for which to retrieve the attributeId. |
 SdaiAttr | attributeId | Variable that will receive the returned attributeId. |
 SdaiInvocationId | edmiInvocationId | Currently not used. |
Return Value
Â
Options
 Â
Â
Example
Â
 EdmiError rstat; SdaiServerContext myContext; SdaiInstance instId; SdaiModel modelId; SdaiEntity entityId; SdaiAttr nameAttrId, ageAttrId; SdaiAttr weightAttrId, marriedAttrId; /* Create Server Context */ rstat = edmiDefineServerContext("MyContext", "Johnny", "Supervisor", "cf37ftr", "TCP", "9090", "MyServerHost", NULL, NULL, NULL, NULL, NULL, &myContext); /* Get the model Id */ rstat = edmiRemoteGetModelBN(myContext, "DataRepository", "MySocialNetwork", &modelId, NULL); /* Get the entity Id */ rstat = edmiRemoteGetEntity(myContext, modelId, "PERSON", &entityId, NULL); /* Get the attribute Ids */ rstat = edmiRemoteGetAttrDefinitionBN(myContext, "SocialNetwork", "Person", "NAME", &nameAttrId, NULL); rstat = edmiRemoteGetAttrDefinitionBN(myContext, "SocialNetwork", "Person", "AGE", &ageAttrId, NULL); rstat = edmiRemoteGetAttrDefinitionBN(myContext, "SocialNetwork", "Person", "WEIGHT", &weightAttrId, NULL); rstat = edmiRemoteGetAttrDefinitionBN(myContext, "SocialNetwork", "Person", "MARRIED", &marriedAttrId, NULL); /* Add lucy to my social network */ rstat = edmiRemoteCreateInstanceAndPutAttrs(myContext, modelId, entityId, 4, &instId, NULL, nameAttrId, sdaiSTRING, "Lucy Schmidt", ageAttrId, sdaiINTEGER, 32, weightAttrId, sdaiREAL, 59.5, marriedAttrId, sdaiBOOLEAN, sdaiFALSE); . . .
Â
See also
Filter by label
There are no items with the selected labels at this time.
Â