private void execProcOrFunc(HplsqlParser.Expr_func_paramsContext ctx, ParserRuleContext procCtx, String name) {
    exec.callStackPush(name);
    HashMap<String, Var> out = new HashMap<>();
    ArrayList<Var> actualParams = getActualCallParameters(ctx);
    exec.enterScope(Scope.Type.ROUTINE);
    callWithParameters(ctx, procCtx, out, actualParams);
    exec.callStackPop();
    exec.leaveScope();
    for (Map.Entry<String, Var> i : out.entrySet()) { // Set OUT parameters
      exec.setVariable(i.getKey(), i.getValue());
    }
  }
Execute a stored procedure using CALL or EXEC statement passing parameters
hplsql/src/main/java/org/apache/hive/hplsql/functions/HmsFunctionRegistry.java