Package org.apache.hadoop.hive.ql.parse

Examples of org.apache.hadoop.hive.ql.parse.ParseDriver


    return pd.parse(qMap.get(tname));
  }

  public void resetParser() throws SemanticException {
    drv.init();
    pd = new ParseDriver();
    sem = new SemanticAnalyzer(conf);
  }
View Full Code Here


      ctx = new Context(conf);
      ctx.setTryCount(getTryCount());
      ctx.setCmd(command);
      ctx.setHDFSCleanup(true);

      ParseDriver pd = new ParseDriver();
      ASTNode tree = pd.parse(command, ctx);
      tree = ParseUtils.findRootNonNullToken(tree);

      BaseSemanticAnalyzer sem = SemanticAnalyzerFactory.get(conf, tree);
      List<AbstractSemanticAnalyzerHook> saHooks =
          getHooks(HiveConf.ConfVars.SEMANTIC_ANALYZER_HOOK,
View Full Code Here

    TaskFactory.resetId();

    try {
      ctx = new Context(conf);

      ParseDriver pd = new ParseDriver();
      ASTNode tree = pd.parse(command, ctx);
      tree = ParseUtils.findRootNonNullToken(tree);

      BaseSemanticAnalyzer sem = SemanticAnalyzerFactory.get(conf, tree);
      // Do semantic analysis and plan generation
      sem.analyze(tree, ctx);
View Full Code Here

    TaskFactory.resetId();

    try {
      ctx = new Context (conf);

      ParseDriver pd = new ParseDriver();
      ASTNode tree = pd.parse(command);

      while ((tree.getToken() == null) && (tree.getChildCount() > 0)) {
        tree = (ASTNode) tree.getChild(0);
      }
View Full Code Here

    // System.out.flush();
   
    db = Hive.get(conf);
    fs = FileSystem.get(conf);
    drv = new Driver(conf);
    pd = new ParseDriver();
    sem = new SemanticAnalyzer(conf);
  }
View Full Code Here

      String command) throws SemanticException{
    Context ctx;
    ParseContext subPCtx = null;
    try {
      ctx = new Context(conf);
      ParseDriver pd = new ParseDriver();
      ASTNode tree = pd.parse(command, ctx);
      tree = ParseUtils.findRootNonNullToken(tree);

      BaseSemanticAnalyzer sem = SemanticAnalyzerFactory.get(conf, tree);
      assert(sem instanceof SemanticAnalyzer);
      doSemanticAnalysis((SemanticAnalyzer) sem, tree, ctx);
View Full Code Here

      command = new VariableSubstitution().substitute(conf,command);
      ctx = new Context(conf);
      ctx.setTryCount(getTryCount());
      ctx.setCmd(command);

      ParseDriver pd = new ParseDriver();
      ASTNode tree = pd.parse(command, ctx);
      tree = ParseUtils.findRootNonNullToken(tree);

      BaseSemanticAnalyzer sem = SemanticAnalyzerFactory.get(conf, tree);
      List<AbstractSemanticAnalyzerHook> saHooks = getSemanticAnalyzerHooks();
View Full Code Here

      ctx.clear();
      ctx.makeScratchDir();
      resStream = null;
     
      pd = new ParseDriver();
      CommonTree tree = pd.parse(command);

      while((tree.getToken() == null) && (tree.getChildCount() > 0)) {
        tree = (CommonTree)tree.getChild(0);
      }
View Full Code Here

    // System.out.flush();
   
    db = Hive.get(conf);
    fs = FileSystem.get(conf);
    drv = new Driver(conf);
    pd = new ParseDriver();
    sem = new SemanticAnalyzer(conf);
  }
View Full Code Here

      String command) throws SemanticException{
    Context ctx;
    ParseContext subPCtx = null;
    try {
      ctx = new Context(conf);
      ParseDriver pd = new ParseDriver();
      ASTNode tree = pd.parse(command, ctx);
      tree = ParseUtils.findRootNonNullToken(tree);

      BaseSemanticAnalyzer sem = SemanticAnalyzerFactory.get(conf, tree);
      assert(sem instanceof SemanticAnalyzer);
      doSemanticAnalysis((SemanticAnalyzer) sem, tree, ctx);
View Full Code Here

TOP

Related Classes of org.apache.hadoop.hive.ql.parse.ParseDriver

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.