getColumnLabel(int column)

Syntax:

String getColumnLabel(int column)
                      throws SQLException

Description:

Gets the designated column's suggested title for use in printouts and displays. The suggested title is usually specified by the SQL AS clause. If an SQL AS is not specified, the value returned from getColumnLabel will be the same as the value returned by the getColumnName method.

Parameters:

column

the first column is 1, the second is 2, ...

Returns:

the suggested column title

Throws:

SQLException - if a database access error occurs, column is less than 1 or greater than the number of columns or the object has been closed.

Reference:

For more information, reference JDBC documentation for: ResultSetMetaData.getColumnLabel(int)