Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions contrib/src/test/queries/clientpositive/dboutput.q
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
--!qt:database:derby:qdb
--! qt:dataset:src
set hive.optimize.limit=false;
set hive.mapred.mode=nonstrict;
Expand All @@ -20,47 +21,46 @@ DESCRIBE FUNCTION EXTENDED dboutput;

EXPLAIN FROM src

SELECT dboutput ( 'jdbc:derby:../build/test_dboutput_db\;create=true','','',
SELECT dboutput ( '${system:hive.test.database.qdb.jdbc.url}','','',
'CREATE TABLE app_info ( kkey VARCHAR(255) NOT NULL, vvalue VARCHAR(255) NOT NULL, UNIQUE(kkey))' ),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
dboutput('${system:hive.test.database.qdb.jdbc.url}','','',
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','a'),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
dboutput('${system:hive.test.database.qdb.jdbc.url}','','',
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','b')

limit 1;


FROM src

SELECT dboutput ( 'jdbc:derby:../build/test_dboutput_db\;create=true','','',
SELECT dboutput ( '${system:hive.test.database.qdb.jdbc.url}','','',
'CREATE TABLE app_info ( kkey INTEGER NOT NULL, vvalue VARCHAR(255) NOT NULL, UNIQUE(kkey))' ),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
dboutput('${system:hive.test.database.qdb.jdbc.url}','','',
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','a'),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
dboutput('${system:hive.test.database.qdb.jdbc.url}','','',
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','b')

limit 1;

EXPLAIN SELECT

dboutput('jdbc:derby:../build/test_dboutput_db','','',
dboutput('${system:hive.test.database.qdb.jdbc.url}','','',
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)',key,value)

FROM src WHERE key < 10;


SELECT

dboutput('jdbc:derby:../build/test_dboutput_db','','',
dboutput('${system:hive.test.database.qdb.jdbc.url}','','',
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)',key,value)

FROM src WHERE key < 10;

dfs -rmr ../build/test_dboutput_db;
dfs -rmr derby.log;

DROP TEMPORARY FUNCTION dboutput;
36 changes: 18 additions & 18 deletions contrib/src/test/results/clientpositive/dboutput.q.out
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ Function class:org.apache.hadoop.hive.contrib.genericudf.example.GenericUDFDBOut
Function type:TEMPORARY
PREHOOK: query: EXPLAIN FROM src

SELECT dboutput ( 'jdbc:derby:../build/test_dboutput_db\;create=true','','',
#### A masked pattern was here ####
'CREATE TABLE app_info ( kkey VARCHAR(255) NOT NULL, vvalue VARCHAR(255) NOT NULL, UNIQUE(kkey))' ),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','a'),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','b')

limit 1
Expand All @@ -39,13 +39,13 @@ PREHOOK: Input: default@src
#### A masked pattern was here ####
POSTHOOK: query: EXPLAIN FROM src

SELECT dboutput ( 'jdbc:derby:../build/test_dboutput_db\;create=true','','',
#### A masked pattern was here ####
'CREATE TABLE app_info ( kkey VARCHAR(255) NOT NULL, vvalue VARCHAR(255) NOT NULL, UNIQUE(kkey))' ),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','a'),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','b')

limit 1
Expand All @@ -64,7 +64,7 @@ STAGE PLANS:
alias: src
Statistics: Num rows: 500 Data size: 5312 Basic stats: COMPLETE Column stats: COMPLETE
Select Operator
expressions: dboutput('jdbc:derby:../build/test_dboutput_db;create=true','','','CREATE TABLE app_info ( kkey VARCHAR(255) NOT NULL, vvalue VARCHAR(255) NOT NULL, UNIQUE(kkey))') (type: int), dboutput('jdbc:derby:../build/test_dboutput_db','','','INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','a') (type: int), dboutput('jdbc:derby:../build/test_dboutput_db','','','INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','b') (type: int)
#### A masked pattern was here ####
outputColumnNames: _col0, _col1, _col2
Statistics: Num rows: 500 Data size: 6000 Basic stats: COMPLETE Column stats: COMPLETE
Limit
Expand All @@ -87,13 +87,13 @@ STAGE PLANS:

PREHOOK: query: FROM src

SELECT dboutput ( 'jdbc:derby:../build/test_dboutput_db\;create=true','','',
#### A masked pattern was here ####
'CREATE TABLE app_info ( kkey INTEGER NOT NULL, vvalue VARCHAR(255) NOT NULL, UNIQUE(kkey))' ),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','a'),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','b')

limit 1
Expand All @@ -102,13 +102,13 @@ PREHOOK: Input: default@src
#### A masked pattern was here ####
POSTHOOK: query: FROM src

SELECT dboutput ( 'jdbc:derby:../build/test_dboutput_db\;create=true','','',
#### A masked pattern was here ####
'CREATE TABLE app_info ( kkey INTEGER NOT NULL, vvalue VARCHAR(255) NOT NULL, UNIQUE(kkey))' ),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','a'),

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)','20','b')

limit 1
Expand All @@ -118,7 +118,7 @@ POSTHOOK: Input: default@src
0 0 1
PREHOOK: query: EXPLAIN SELECT

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)',key,value)

FROM src WHERE key < 10
Expand All @@ -127,7 +127,7 @@ PREHOOK: Input: default@src
#### A masked pattern was here ####
POSTHOOK: query: EXPLAIN SELECT

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)',key,value)

FROM src WHERE key < 10
Expand All @@ -150,7 +150,7 @@ STAGE PLANS:
predicate: (UDFToDouble(key) < 10.0D) (type: boolean)
Statistics: Num rows: 166 Data size: 29548 Basic stats: COMPLETE Column stats: COMPLETE
Select Operator
expressions: dboutput('jdbc:derby:../build/test_dboutput_db','','','INSERT INTO app_info (kkey,vvalue) VALUES (?,?)',key,value) (type: int)
#### A masked pattern was here ####
outputColumnNames: _col0
Statistics: Num rows: 166 Data size: 664 Basic stats: COMPLETE Column stats: COMPLETE
File Output Operator
Expand All @@ -170,7 +170,7 @@ STAGE PLANS:

PREHOOK: query: SELECT

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)',key,value)

FROM src WHERE key < 10
Expand All @@ -179,7 +179,7 @@ PREHOOK: Input: default@src
#### A masked pattern was here ####
POSTHOOK: query: SELECT

dboutput('jdbc:derby:../build/test_dboutput_db','','',
#### A masked pattern was here ####
'INSERT INTO app_info (kkey,vvalue) VALUES (?,?)',key,value)

FROM src WHERE key < 10
Expand Down

This file was deleted.

This file was deleted.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

This file was deleted.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

This file was deleted.

14 changes: 0 additions & 14 deletions itests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -520,20 +520,6 @@
</target>
</configuration>
</execution>
<execution>
<id>copy-database</id>
<phase>install</phase>
<configuration>
<tasks>
<copy todir="${hive.path.to.root}/itests/qtest/target/db_for_connectortest.db">
<fileset dir="${hive.path.to.root}/data/files/dataconnector_derbydb/db_for_connectortest.db"/>
</copy>
</tasks>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
Expand Down
Loading