Connection.odbcGetInfoLong Method [AX 2012]

Provides an interface to the SQLGetInfo ODBC function to retrieve information about the ODBC driver and data source that are associated with a connection.

public int odbcGetInfoLong(int InfoId)

Run On

Server

Parameters

InfoId
Type: int
An Integer data type that specifies an ID for the requested information, according to the ODBC standard.

Return Value

Type: int
An Integer data type value for the information that is retrieved.

This method retrieves a 32-bit integer and returns it as an integer.

In the following example, the odbcGetInfoLong method returns an integer for the maximum row size.

void getConnection() 
{ 
    Connection con; 
    Statement stmt; 
    int info; 
 
    #define.SQL_MAX_ROW_SIZE(104) 
    con = new Connection(); 
 
    try 
    { 
        info = con.odbcGetInfoLong(#SQL_MAX_ROW_SIZE); 
 
        print info; 
        pause; 
     } 
 
    catch(exception::Error) 
    { 
        print "An error occurred."; 
 
    } 
 
}

Community Additions

ADD
Show: