Maptitude GISDK Help

AddIDField()

Summary

Adds an ID field to an existing table.

 

Syntax

AddIDField(string view_name, integer start, integer step, boolean indexed_flag, string newfldname, string where, array options)

 

Argument

Contents

view_name

The name of the view of a table; if omitted, the current table is used

start

The index of the first element; if omitted, indexing starts at 1

step

The increment to use (the default is 1)

indexed_flag

If the new ID field is to be a permanent index to the table (the default is "False")

newfldname

The proposed name of the new ID field (the default is "ID")

where

Indicates where to place the new ID field. This can be "left" or "right", meaning the field will be the leftmost or rightmost field of the table, or "auto" (the default), which means the choice of leftmost or rightmost position will be made automatically

 

No options are currently supported.

 

Returns

The actual name of the field that was added.

 

Notes

Example

fld_name = AddIDField("MyTable", 1000, 1, "False", "NewID", "auto", )

 

Error Codes

Error Type

Meaning

NotFound

No view with this name was found, or no current view was found

Error

The table cannot be modified

 

 

©2025 Caliper Corporation www.caliper.com