Class Reference
IRIS for UNIX 2024.1.2
InterSystems: The power behind what matters   
Documentation  Search
  [USER] >  [EnsLib] >  [RecordMap] >  [Model] >  [Field]
Private  Storage   

class EnsLib.RecordMap.Model.Field extends EnsLib.RecordMap.Model.RecordProperty

Server side class to model the Field object used in the RecordMap model. Both fixed width and delimited fields are described by this model.

Inventory

Parameters Properties Methods Queries Indices ForeignKeys Triggers
7 5


Summary

Properties
RecordType annotation datatype ignored index
name params repeating required sqlColumn
trailingData width

Methods
%AddToSaveSet %ClassIsLatestVersion %ClassName %ConstructClone
%DispatchClassMethod %DispatchGetModified %DispatchGetProperty %DispatchMethod
%DispatchSetModified %DispatchSetMultidimProperty %DispatchSetProperty %Extends
%GetParameter %IsA %IsModified %New
%NormalizeObject %ObjectModified %OriginalNamespace %PackageName
%RemoveFromSaveSet %SerializeObject %SetModified %ValidateObject
GetFieldName GetObjectName XMLDTD XMLExport
XMLExportToStream XMLExportToString XMLNew XMLSchema
XMLSchemaNamespace XMLSchemaType nameIsValid


Properties

• property datatype as %String(XMLPROJECTION="ATTRIBUTE");
The datatype to be used for the data. If not specified, a %String type will be used.
• property index as %String(VALUELIST=",,1,bitmap,idkey,unique",XMLPROJECTION="ATTRIBUTE");
Indicate whether the generated property should be indexed. This only applies to persistent classes.
• property params as %String(MAXLEN=1000,XMLPROJECTION="ATTRIBUTE");
List of parameters for datatype. The format is a semicolon-separated list of key/value pairs as follows:
  PARAM1=value1;PARAM2=value2;FORMAT=2;...
Leading and trailing whitespace will be ignored. This will be most useful for datatypes like dates or special numeric types. NOTE: MAXLEN parameters are automatically calculated for fixed width fields.
• property repeating as EnsLib.RecordMap.Model.DataType.Boolean(XMLPROJECTION="ATTRIBUTE");
Indicate whether the property is repeating. This only has meaning in delimited Records, and will report an error if enabled for fixed width Records.
• property sqlColumn as %Integer(MAXVAL=4096,MINVAL=2,XMLPROJECTION="ATTRIBUTE");
The SQL column number of the field. This value must either not be specified, or must lie between 2 and 4096 (inclusive) as per the values for the SqlColumnNumber property keyword. The column number is of particular use when importing data from CSV files or similar data dumps, as the SQL representation can be replicated easily.
• property trailingData as %String(XMLPROJECTION="ATTRIBUTE");
Characters which will follow the field, as can happen with some fixed width formats. Note that if there is not an exact match between the incoming data and these characters, the RecordMap parser will immediately throw an error. Only valid for fixed width RecordMaps.
• property width as %Integer(XMLPROJECTION="ATTRIBUTE");
Number of characters containing this field's data. Only valid for fixed width RecordMaps.

Methods

• method GetFieldName() as %String
Get the field part of the name, which equates to the part of the name following the last "." character.
• method GetObjectName() as %String
Get the object part of the name, which equates to all parts of the name prior to the last ".", with any "$" characters removed.
• classmethod nameIsValid(%val) as %Status
Validate the value of the name property - ensure the generated property name requested by the user is valid.


Copyright (c) 2025 by InterSystems Corporation. Cambridge, Massachusetts, U.S.A. All rights reserved. Confidential property of InterSystems Corporation.