37

I know that we can make a single line comment with '--' in hiveQL(hive.sql scripts) but is there a way to make multi line comments? I need something like below

/*  This sentence is 
    a comment */
Tomasz Nurkiewicz
  • 334,321
  • 69
  • 703
  • 674
Karthick
  • 2,844
  • 4
  • 34
  • 55

3 Answers3

30

As per my knowledge, multi-line comments are not supported in Hive scripts as of now. Seems like this JIRA introduced only single line comments, starting with -- in Hive 0.8

Mark Grover
  • 4,070
  • 22
  • 21
13

No, As of now Hive support single line comment only.

Hive, Pig, Hbase are starting stage not implemented like Mangodb, Cassandra, but in next version especially for Hadoop 2.x it's possible multiple comments also.

Just use -- two dashes to make a comment in hive.

Venu A Positive
  • 2,992
  • 2
  • 28
  • 31
6

Multi-line (aka "bracketed") comments should be available in Hive v2.3.0: https://issues.apache.org/jira/browse/HIVE-15765

combinatorist
  • 562
  • 1
  • 4
  • 17