📚 SAP Business One SDK Help

GetTableFieldList Method
See Also 
TableName
Table name in the database.

Description

Returns a Recordset object that contains the fields list of a specified table in the database. Each field includes the following parameters (the examples in parenthesis relates to OCRD: CardCode):

  • Name (CardCode)
  • Type (nvarchar) -- a numeric value representing a BoFieldTypes enumeration value
  • Length (15)
  • Linked table name for foreign key (GroupCode)
  • Valid values indicator, which indicates whether or not this field uses valid values (no)
  • IsNullable -- specifies whether or not nulls are permitted

Syntax

Visual Basic
Public Function GetTableFieldList( _
   ByVal TableName As String _
) As Recordset

Parameters

TableName
Table name in the database.

Remarks

The following is a returned recordset that is saved in XML format:

<?xml version="1.0" encoding="UTF-16"?>
<BOM>
<BO>
<AdmInfo>
<Object>-1</Object>
</AdmInfo>
<GENREC>
<row>
<FieldName>CardCode</FieldName>
<FieldLength>15</FieldLength>
<FieldType>0</FieldType>
<IsNullable>0</IsNullable>
<IsValidValues>0</IsValidValues>
<LinkedTo/>
</row>
<row>
<FieldName>CardName</FieldName>
<FieldLength>100</FieldLength>
<FieldType>0</FieldType>
<IsNullable>0</IsNullable>
<IsValidValues>0</IsValidValues>
<LinkedTo/>
</row>
</GENREC>
</BO>
</BOM>

See Also