public ArgumentListFunctionExpression coalesce() { ListExpressionOperator coalesceOperator = (ListExpressionOperator)getOperator(ExpressionOperator.Coalesce); ListExpressionOperator clonedCoalesceOperator = new ListExpressionOperator(); coalesceOperator.copyTo(clonedCoalesceOperator); ArgumentListFunctionExpression expression = new ArgumentListFunctionExpression(); expression.setBaseExpression(this); expression.setOperator(clonedCoalesceOperator); return expression; }
public ArgumentListFunctionExpression coalesce() { ListExpressionOperator coalesceOperator = (ListExpressionOperator)getOperator(ExpressionOperator.Coalesce); ListExpressionOperator clonedCoalesceOperator = new ListExpressionOperator(); coalesceOperator.copyTo(clonedCoalesceOperator); ArgumentListFunctionExpression expression = new ArgumentListFunctionExpression(); expression.setBaseExpression(this); expression.setOperator(clonedCoalesceOperator); return expression; }
return new ArgumentListFunctionExpression(); } else if (this.nodeClass == ClassConstants.FunctionExpression_Class) { return new FunctionExpression();
return new ArgumentListFunctionExpression(); } else if (this.nodeClass == ClassConstants.FunctionExpression_Class) { return new FunctionExpression();
/** * INTERNAL: * Creates an ArgumentListFunctionExpression that is capable of creating a case statement of the form: * <blockquote><pre> * SQL: CASE name WHEN "Robert" THEN "Bob" * WHEN "Susan" THEN "Sue" * ELSE "No-Nickname" * </pre></blockquote> * * This expression must be manipulated to successfully build a case statement by adding appropriate * children to it. * * A child must be added for the "case expression" (name above), a pair of children must be added for * each "when then" expression and a child must be added for the else. * * @see ArgumentListFunctionExpression */ public ArgumentListFunctionExpression caseStatement() { ListExpressionOperator caseOperator = (ListExpressionOperator)getOperator(ExpressionOperator.Case); ListExpressionOperator clonedCaseOperator = new ListExpressionOperator(); caseOperator.copyTo(clonedCaseOperator); ArgumentListFunctionExpression expression = new ArgumentListFunctionExpression(); expression.setBaseExpression(this); expression.setOperator(clonedCaseOperator); return expression; }
/** * INTERNAL: * Creates an ArgumentListFunctionExpression that is capable of creating a case statement of the form: * <blockquote><pre> * SQL: CASE WHEN name = "Robert" THEN "Bob" * WHEN name = "Susan" THEN "Sue" * ELSE "No-Nickname" * </pre></blockquote> * * This expression must be manipulated to successfully build a case statement by adding appropriate * children to it. * * A pair of children must be added for each "when then" expression and a child must be added for the else. * * @see ArgumentListFunctionExpression */ public ArgumentListFunctionExpression caseConditionStatement() { ListExpressionOperator caseOperator = (ListExpressionOperator)getOperator(ExpressionOperator.CaseCondition); ListExpressionOperator clonedCaseOperator = new ListExpressionOperator(); caseOperator.copyTo(clonedCaseOperator); ArgumentListFunctionExpression expression = new ArgumentListFunctionExpression(); expression.setBaseExpression(this); expression.setOperator(clonedCaseOperator); return expression; }
/** * INTERNAL: * Creates an ArgumentListFunctionExpression that is capable of creating a case statement of the form: * <blockquote><pre> * SQL: CASE name WHEN "Robert" THEN "Bob" * WHEN "Susan" THEN "Sue" * ELSE "No-Nickname" * </pre></blockquote> * * This expression must be manipulated to successfully build a case statement by adding appropriate * children to it. * * A child must be added for the "case expression" (name above), a pair of children must be added for * each "when then" expression and a child must be added for the else. * * @see ArgumentListFunctionExpression */ public ArgumentListFunctionExpression caseStatement() { ListExpressionOperator caseOperator = (ListExpressionOperator)getOperator(ExpressionOperator.Case); ListExpressionOperator clonedCaseOperator = new ListExpressionOperator(); caseOperator.copyTo(clonedCaseOperator); ArgumentListFunctionExpression expression = new ArgumentListFunctionExpression(); expression.setBaseExpression(this); expression.setOperator(clonedCaseOperator); return expression; }
/** * INTERNAL: * Creates an ArgumentListFunctionExpression that is capable of creating a case statement of the form: * <blockquote><pre> * SQL: CASE WHEN name = "Robert" THEN "Bob" * WHEN name = "Susan" THEN "Sue" * ELSE "No-Nickname" * </pre></blockquote> * * This expression must be manipulated to successfully build a case statement by adding appropriate * children to it. * * A pair of children must be added for each "when then" expression and a child must be added for the else. * * @see ArgumentListFunctionExpression */ public ArgumentListFunctionExpression caseConditionStatement() { ListExpressionOperator caseOperator = (ListExpressionOperator)getOperator(ExpressionOperator.CaseCondition); ListExpressionOperator clonedCaseOperator = new ListExpressionOperator(); caseOperator.copyTo(clonedCaseOperator); ArgumentListFunctionExpression expression = new ArgumentListFunctionExpression(); expression.setBaseExpression(this); expression.setOperator(clonedCaseOperator); return expression; }
public ArgumentListFunctionExpression coalesce() { ListExpressionOperator anOperator = new ListExpressionOperator(); anOperator.setSelector(ExpressionOperator.Coalesce); anOperator.setNodeClass(FunctionExpression.class); anOperator.setType(ExpressionOperator.FunctionOperator); anOperator.bePrefix(); anOperator.setStartString("COALESCE("); anOperator.setSeparator(","); anOperator.setTerminationString(" )"); ArgumentListFunctionExpression expression = new ArgumentListFunctionExpression(); expression.setBaseExpression(this); expression.setOperator(anOperator); return expression; }
operator.setTerminationStrings(new String[]{" ELSE ", " END "}); ArgumentListFunctionExpression expression = new ArgumentListFunctionExpression(); expression.setBaseExpression(this);
operator.setTerminationStrings(new String[]{" ELSE ", " END"}); ArgumentListFunctionExpression expression = new ArgumentListFunctionExpression(); expression.setBaseExpression(this);