---
title: "hive 常用命令"
author: "乡里伢崽"
date: "2014-07-17T22:22:47Z"
tags: []
categories: ["编程语言"]
slug: "hive"
draft: false
lastmod: "2014-07-17T22:22:47Z"
id: 2093440
url: "https://crazymatrix.iteye.com/blog/2093440"
---

1.hive通过外部设置参数传入脚本中：
       hive -hiveconf enter_school_date="20130902" -hiveconf min_ag="26" -f testvar.sql
       脚本调用参数：use test; 
             select * from student where pdate='${hiveconf:enter_school_date}' and  sage > '${hiveconf:min_ag}' limit 8;