Hi,
I tried running a small script with both TeraJDBC 16.00.00.23 and TeraJDBC 15.00.00.20 I try to use setClientInfo and it keeps returning
Exception! java.sql.SQLClientInfoException: [Teradata JDBC Driver] [TeraJDBC 15.00.00.20] [Error 165] [SQLState HY000] setClientInfo(String,String): function not supported in this version at com.teradata.jdbc.jdk6.JDK6_SQL_Connection.setClientInfo(JDK6_SQL_Connection.java:112)
But I looked into JDK6_SQL_Connection.class in both drivers and found:
public void setClientInfo(String paramString1, String paramString2)
throws SQLClientInfoException
{
SQLException localSQLException = ErrorFactory.makeDriverJDBCException("TJ215", "setClientInfo(String,String)");
throw new SQLClientInfoException(localSQLException.getMessage(), localSQLException.getSQLState(), localSQLException.getErrorCode(), Collections.EMPTY_MAP, localSQLException);
}
public void setClientInfo(Properties paramProperties)
throws SQLClientInfoException
{
SQLException localSQLException = ErrorFactory.makeDriverJDBCException("TJ215", "setClientInfo(Properties)");
throw new SQLClientInfoException(localSQLException.getMessage(), localSQLException.getSQLState(), localSQLException.getErrorCode(), Collections.EMPTY_MAP, localSQLException);
}
So it is there.
I used both the properties and string.
Is this a bug?
While you can use getClientInfo to retrieve Query Band information, setClientInfo is not supported.
To set query band values, you must execute a "SET QUERY_BAND ..." SQL statement.
I figured as such, but I wanted to get a confirmation from Teradata itself.
Thank you.
This feature is on our product roadmap:
JDBC RFC 170251 Implement Connection.setClientInfo to set query band