/* */
/* 439 */ Node child0 = select.jjtGetChild(0);
/* */
/* 441 */ if ((child0 instanceof ASTPath))
/* */ {
/* 443 */ ASTPath path = (ASTPath)child0;
/* */
/* 445 */ if (path.isCMPField())
/* */ {
/* 448 */ JDBCFieldBridge selectField = path.getCMPField();
/* 449 */ this.selectManager = selectField.getManager();
/* 450 */ this.selectObject = selectField;
/* 451 */ setTypeFactory(this.selectManager.getJDBCTypeFactory());
/* */
/* 455 */ addInnerJoinPath(path);
/* */
/* 457 */ String alias = this.aliasManager.getAlias(path.getPath(path.size() - 2));
/* 458 */ SQLUtil.getColumnNamesClause(selectField, alias, sql);
/* */ }
/* */ else
/* */ {
/* 462 */ JDBCAbstractEntityBridge selectEntity = (JDBCAbstractEntityBridge)path.getEntity();
/* 463 */ this.selectManager = selectEntity.getManager();
/* 464 */ this.selectObject = selectEntity;
/* 465 */ setTypeFactory(selectEntity.getManager().getJDBCTypeFactory());
/* */
/* 467 */ String alias = this.aliasManager.getAlias(path.getPath());
/* 468 */ if (select.distinct)
/* */ {
/* 470 */ SQLUtil.getSearchableColumnNamesClause(selectEntity.getTableFields(), alias, sql);
/* */ }
/* */ else
/* */ {
/* 474 */ SQLUtil.getColumnNamesClause(selectEntity.getTableFields(), alias, sql);
/* */ }
/* */
/* 491 */ addLeftJoinPath(path);
/* */ }
/* */
/* */ }
/* */ else
/* */ {
/* 497 */ ASTPath path = getPathFromChildren(child0);
/* */
/* 499 */ if (path == null)
/* */ {
/* 501 */ throw new IllegalStateException("The function in SELECT clause does not contain a path expression.");
/* */ }
/* */
/* 504 */ if (path.isCMPField())
/* */ {
/* 506 */ JDBCFieldBridge selectField = path.getCMPField();
/* 507 */ this.selectManager = selectField.getManager();
/* 508 */ setTypeFactory(this.selectManager.getJDBCTypeFactory());
/* */ }
/* 510 */ else if (path.isCMRField())
/* */ {
/* 512 */ JDBCFieldBridge cmrField = (JDBCFieldBridge)path.getCMRField();
/* 513 */ this.selectManager = cmrField.getManager();
/* 514 */ setTypeFactory(this.selectManager.getJDBCTypeFactory());
/* 515 */ addLeftJoinPath(path);
/* */ }
/* */ else
/* */ {
/* 519 */ JDBCAbstractEntityBridge entity = (JDBCAbstractEntityBridge)path.getEntity();
/* 520 */ this.selectManager = entity.getManager();
/* 521 */ setTypeFactory(this.selectManager.getJDBCTypeFactory());
/* 522 */ addLeftJoinPath(path);
/* */ }
/* */