Error: Invalid spaceKey on retrieving a related space config.

ARDeleteSchema

Note

You can continue to use C APIs to customize your application, but C APIs are not enhanced to support new capabilities provided by Java APIs and REST APIs.

Description

Deletes the form with the indicated name from the specified server and deletes any container references to the form. Depending on the value that you specify for the deleteOption parameter, the form is deleted from the server immediately and is not returned to users who request information about forms. In addition, the system deletes all entries, fields, views (VUIs), active links, escalations, and filters associated with the form and all containers owned by the form.

Privileges

BMC Remedy AR System administrator.

Synopsis

#include "ar.h"
#include "arerrno.h"
#include "arextern.h"
#include "arstruct.h"

int ARDeleteSchema(
   ARControlStruct *control,
   ARNameType name,
   unsigned int deleteOption,
   char *objectModificationLogLabel,
   ARStatusList *status)

Input arguments

control

The control record for the operation. It contains information about the user requesting the operation, where that operation is to be performed, and which session is used to perform it. The user and server fields are required.

If a valid overlay group is specified in the control record, the ARDelete* function operates on the object that belongs to that group. If no group is specified, the function operates on the origin object. To specify whether to use an object's real or resolved name in an operation and whether to perform the operation only on objects in a specified overlay group, use the AR_SESS_CONTROL_PROP_DESIGN_OVERLAYGROUP variable of the ARSetSessionConfiguration function (see ARGetSessionConfiguration).

name

The name of the form to delete.

deleteOption

A bitmask that indicates the action to take if the specified form contains entries (only applicable to base forms) or is a member of a join form.

Bit 0:

Delete schema only when there is no dependency and there is no data in the schema, set the bit to zero (0). This is ignored in the case of a join form (AR_SCHEMA_CLEAN_DELETE). To delete schema even if there is data, set the bit to one (1). This is applicable only to regular schemas (AR_SCHEMA_DATA_DELETE).

Bit 1:

Delete schema even if there is a dependency. All the specified schemas are deleted. This option overrides AR_SCHEMA_DATA_DELETE (AR_SCHEMA_FORCE_DELETE).

Bit 2:

Delete the given object and all objects that are locked with the same key. This is applicable only to locked objects (AR_LOCK_BLOCK_DELETE).

Bit 3:

Delete the archive form even if archive is enabled or the archive form if part of a lock block (AR_SCHEMA_SHADOW_DELETE).

 

objectModificationLogLabel

The version control label that the API function must apply to the object. If the label name does not exist on the server, the function creates it.

Ripple actions

The Rename and Delete operations typically change multiple objects in addition to their primary target object. The Rename or Delete function must apply the version control label to all the objects that it affects.

Multiple API calls for a single user action 

Some user actions trigger a sequence of API calls. In that situation, the last API call in the sequence applies the version control label to the object. Thus, clients that create forms (like BMC Remedy Developer Studio does) should provide the label only to the last call. For example, when a form is created, a client might issue these calls:

  • ARCreateSchema
  • ARCreateMultipleFields
  • ARSetVUI
  • ARSetVUI
  • ARSetSchema

In this case, the objectModificationLogLabel value should be passed only to the last call, ARSetSchema, even though the user provides the label during the ARCreateSchema operation.

Operations on label-related forms

Version control labels cannot be applied to these forms:

  • AR System Version Control: Label
  • AR System Version Control: Labeled Object
  • AR System Version Control: Object Modification Log

Return values

status

A list of zero or more notes, warnings, or errors generated from a call to this function. For a description of all possible values, see Error checking.

See also

ARCreateSchema, ARGetSchema, ARGetListAlertUser, ARSetSchema. See FreeAR for: FreeARStatusList.

Was this page helpful? Yes No Submitting... Thank you

Comments