sdaiUnsetAggrByIndex


Set the specified ARRAY element value to indeterminate, i.e. the element value will be unset such that a following EDMinterface operations sdaiTestAggrByIndex and edmiTestAggrByIterator on the same element will return sdaiFALSE. The functions sdaiGetAggrByIndex and sdaiGetAggrByIterator on the same ARRAY element will fail when the element value is indeterminate, i.e. the value is unset. When the actual element value is an aggregate, this aggregate and all child aggregates will be deleted by this operation.
This operation is only applicable on ARRAY aggregates owned by application instances. The actual ARRAY element is specified by the element index. The legal element index range for ARRAY is as found in the actual ARRAY declaration in the related EXPRESS schema.
All elements in an ARRAY have the value indeterminate until an element value is assigned by one of the following operations: sdaiPutAggrByIndex , sdaiPutAggrByIterator , sdaiCreateNestedAggrByIndex , or sdaiCreateNestedAggrByIterator .
The model that holds the actual ARRAY aggregate instance must be open for write access before this operation can successfully performed.
Related functions: sdaiUnsetAggrByIterator , sdaiPutAggrByIndex , sdaiPutAggrByIterator , sdaiCreateNestedAggrByIndex , sdaiCreateNestedAggrByIterator .
Header:
#include "sdai.h"
Prototype:
void sdaiUnsetAggrByIndex(SdaiArray   array,
                           SdaiInteger index); 
Arguments:

array

A numeric arrayID that uniquely identifies the ARRAY aggregate instance of interest in the EDMdatabase.
The arrayID is returned when the aggregate is created or it can be retrieved by an _EDMinterface_ get operation.

index

An integer that denotes the aggregate element index in the ARRAY aggregate instance specified by the <array> argument.
The legal index range is as found in the actual ARRAY declaration in the related EXPRESS schema.

Returns:
Void – use sdaiErrorQuery to check for error in operation.
Examples:
SdaiArray array;
SdaiErrorCode errCode;
...
sdaiUnsetAggrByIndex(array, 1);
if (errCode = sdaiErrorQuery()) {
/* Error in operation */ 
printf("\nError: %s in sdaiUnsetAggrByIndex \n", 
edmiGetErrorText(errCode)); 
goto error; 

}
. . .