HHH-3510 : HQL SQLFunction replacement not occuring when HQL text has no parenthesis (rollback)

git-svn-id: https://svn.jboss.org/repos/hibernate/core/trunk@15266 1b8cb986-b30d-0410-93ca-fae66ebed9b2
This commit is contained in:
Steve Ebersole 2008-10-08 03:13:08 +00:00
parent c3d4758f1e
commit 959d2814ea
1 changed files with 3 additions and 1 deletions

View File

@ -27,6 +27,7 @@ package org.hibernate.hql.ast.tree;
import antlr.SemanticException;
import antlr.collections.AST;
import org.hibernate.QueryException;
import org.hibernate.dialect.function.SQLFunction;
import org.hibernate.hql.antlr.SqlTokenTypes;
import org.hibernate.hql.ast.util.ColumnHelper;
import org.hibernate.persister.collection.QueryableCollection;
@ -289,7 +290,8 @@ public class IdentNode extends FromReferenceNode implements SelectExpression {
if ( fe != null ) {
return fe.getDataType();
}
return null;
SQLFunction sf = getWalker().getSessionFactoryHelper().findSQLFunction( getText() );
return sf == null ? null : sf.getReturnType( null, null );
}
public void setScalarColumnText(int i) throws SemanticException {