NGOAddFieldToDataDefinition

This call is used to add fields to an existing Dataclass. If a field already exists having the same name as the specified one, an error is thrown. It takes as CabinetName, UserDBId and dataclass field information as input and returns the status for the call along with the properties of the fields thus added.

 

Input Parameter description

View sample InputXml

Output Parameter description

View sample OutputXml

Errors and Warnings

 

 

Input Parameters description

Name

Parent Tag

Description

Valid Values

Default

Values

Option

Root

Unique option for the call

NGOAddFieldTo

DataDefinition

 

CabinetName

Root

Name of the cabinet to which the User wants to connect.

 

 

UserDBId

Root

UserDatabase ID, which is returned in the NGOConnectCabinet call.

 

 

DataDefIndex

Root

Index of the dataclass to which the given fields are to be added.

Integer > 0

 

Fields

Root

It contains information about fields to be added.

 

 

Field

Fields

It contains Information for a particular Field.

 

 

IndexId

Field

Index of the field.

 0 – if a new field is added

Integer > 0

 

IndexName

Field

Name of the field.

 

 

IndexType

Field

Type of the field.

Integer, Boolean, Date, Float, Long, String, Text, X (Document Index)

 

IndexLength

Field

Size of the field.

Depends upon Index type.

 

IndexAttribute

Field

Constraint of the field.

0 – null,

1 - not null

2 - unique null,

3 - unique not null

4,5 - same as 0,1 respectively except that they are search keys.

 

UsefulInfoFlag

Field

If a field is marked as Useful Info, value of that field can be seen in the document table under the Useful Data column, which makes the search faster.

Y or N

N

UsefulInfoSize

Field

Size of the field.

Depends upon the Index type.

0

IndexFlag

Field

Information about Index flag whether it would be Global or Data Class level.

Global(G) or Data(D).

 

 

Output Parameters description

Name

Parent Tag

Description

Option

Root

NGOAddFieldToDataDefinition

Status

Root

Status of the call. If the Status is 0, then the call is successful.

DataDefinition

Root

Contains information about the Data field.

DataDefIndex

Data

Definition

Index of the dataclass to which the given fields are added.

DataDefName

Data

Definition

Name of the dataclass.

Comment

Data

Definition

Comments associated with the dataclass.

Type

Data

Definition

Type of the dataclass. Nothing predefined type is there.

GroupId

Data

Definition

Main Group Index of the dataclass.

Extra

Data

Definition

Not Used.

Fields

Data

Definition

Contains information about the fields of Data Class.

Field

Fields

Contain information about a particular field.

IndexId

Field

Index of the added field.

IndexName

Field

Name of the added field.

IndexType

Field

Type of the added field.

IndexLength

Field

Size of the associated field.

IndexFlag

Field

Whether global or Data Class Level field info.

UsefulInfoFlag

Field

UsefulInfoFlag of the added field.

UsefulInfoSize

Field

UsefulInfoSize of the added field.

IndexAttribute

Field

Attribute of the associated field.

 

Errors returned from call

Code

Message

Comments

-50107

Insufficient privileges for the current operation.

The logged-in user has insufficient rights for adding fields to a dataclass.

-50028

Data Class not found.

The specified dataclass not found.

-50146

Invalid session.

The specified UserDBId is incorrect.

-50006

User account has expired.

The account of the user has expired.

-50010

User not alive.

The user is not alive.

-50125

Cabinet has been locked for Administrative purposes.

The cabinet has been locked by some user for Administrative purposes.

-50057

Invalid privileges for the current operation.

Invalid privileges on the specified dataclass.

-50106

Invalid Field attribute.

Incorrect Field attribute.

-50074

Invalid parameters.

The value for some input parameter is not correct or is invalid.

-50047

Invalid Field length.

Incorrect Field length.

-50046

Invalid Field type.

Incorrect Field type.

-50077

Specified Field already associated with Data Class.

The field(s) to be added is (are) already associated with the dataclass.

-50109

One or more field already associated with the Data Class.

The field(s) to be added is (are) already associated with the dataclass.