1399 assert functionQualifier == null;
1400 final int num_operands = operands.length;
1401 if (num_operands < 2 || num_operands > 6) {
1402 throw new IllegalArgumentException(
1403 "Invalid operand count " + Arrays.toString(operands));
1405 SqlNode[] new_operands =
new SqlNode[6];
1408 new_operands[0] = operands[0];
1410 new_operands[1] = operands[1];
1412 if (num_operands < 3 || operands[2] == null) {
1413 new_operands[2] = SqlLiteral.createExactNumeric(
"1", pos);
1415 new_operands[2] = operands[2];
1418 if (num_operands < 4 || operands[3] == null) {
1419 new_operands[3] = SqlLiteral.createExactNumeric(
"1", pos);
1421 new_operands[3] = operands[3];
1424 if (num_operands < 5 || operands[4] == null) {
1425 new_operands[4] = SqlLiteral.createCharString(
"c", pos);
1427 new_operands[4] = operands[4];
1430 if (num_operands < 6 || operands[5] == null) {
1431 new_operands[5] = SqlLiteral.createExactNumeric(
"1", pos);
1433 new_operands[5] = operands[5];
1435 return super.createCall(functionQualifier, pos, new_operands);