Function.ODBC.Connection!ConnectionName.GetID

From GAB Help
Jump to: navigation, search

Given a table and field, this function returns a long integer. If the Increment boolean is set to True, the long return will be equal to the greatest field value, plus one. If the boolean is False, the highest value is returned.

Syntax

Function.ODBC.Connection!conname.GetID(Table name [String], field name [String], increment [Boolean], Return [Long])

Arguments

Table Name

[String]

Field Name

[String]

Increment

[Boolean]

Return

[Long]


Example

Function.ODBC.Connection!con.GetID("ATG_B_SETUP_SHEET","COL_NO",True,V.Local.iRet) 
Function.ODBC.Connection!Conn.GetID("Job_Header","JOB",false,Variable.Local.iRet)

Remarks

This command should only be run against a numeric field.