MSCK REPAIR TABLE hivetest.mytable1
I know this reason
but if I ResultSet rs = st.executeQuery("msck repair table
hivetest.chinese_part1");
I will get a error The query did not generate a result set!
igyu
From: igyu
Date: 2021-09-16 08:59
To: user
Subject: Re: Re: How can I know use execute or executeQuery
thanks
I have a other perblem
when I run "MSCK REPAIR TABLE hivetest.mytable1"
I get a error
Encountered: IDENTIFIER
Expected: ALTER, COMMENT, COMPUTE, COPY, CREATE, DELETE, DESCRIBE, DROP,
EXPLAIN, GRANT, INSERT, INVALIDATE, LOAD, REFRESH, REVOKE, SELECT, SET, SHOW,
TRUNCATE, UPDATE, UPSERT, USE, VALUES, WITH
CAUSED BY: Exception: Syntax error
but I can exec that in hue
I use
<dependency>
<groupId>org.apache.hive</groupId>
<artifactId>hive-jdbc</artifactId>
<version>2.1.1-cdh6.3.2</version>
</dependency>
CDH 6.3.2
igyu
From: Edward Capriolo
Date: 2021-09-15 20:18
To: [email protected]
Subject: Re: How can I know use execute or executeQuery
In most sql drivers.. you can always use executeQuery even if the query has no
result set.
On Wednesday, September 15, 2021, Alessandro Solimando
<[email protected]> wrote:
Hi Igyu,
sending different SQL statements is exactly what beeline has to handle, I'd
have a look at how they handle this:
https://github.com/apache/hive/tree/master/beeline (this seems a good starting
point).
HTH,
Alessandro
On Wed, 15 Sept 2021 at 03:50, igyu <[email protected]> wrote:
SQL is writed by user.
user can write "show tables", "use db"or "select * from table".
so I don't know SQL before send to server.
when SQL into the server how can I know use execute or executeQuery.
SQL type is too many
igyu
--
Sorry this was sent from mobile. Will do less grammar and spell check than
usual.