Hello again.
I'm still fighting to get de prepared statements values i think i have found the explation for not having the values in log.
org.hibernate.loader.Loader
Code:
protected int bindParameterValues(
PreparedStatement statement,
QueryParameters queryParameters,
int startIndex,
SessionImplementor session) throws SQLException {
int span = 0;
span += bindPositionalParameters( statement, queryParameters, startIndex, session );
span += bindNamedParameters( statement, queryParameters.getNamedParameters(), startIndex + span, session );
return span;
}
you can see that he is going to bind parameters by position and by name. When executing the bindNamedParameters a log.debug is made with the values, but executing bindPositionalParameters, no log is made:
Code:
protected int bindPositionalParameters(
final PreparedStatement statement,
final QueryParameters queryParameters,
final int startIndex,
final SessionImplementor session) throws SQLException, HibernateException {
final Object[] values = queryParameters.getFilteredPositionalParameterValues();
final Type[] types = queryParameters.getFilteredPositionalParameterTypes();
int span = 0;
for ( int i = 0; i < values.length; i++ ) {
types[i].nullSafeSet( statement, values[i], startIndex + span, session );
span += types[i].getColumnSpan( getFactory() );
}
return span;
}
When you have only positional parameters to bind to the prepared statement, how can you debug the values? Can anyone help me please?
Thanks.