Support Questions

Find answers, ask questions, and share your expertise
Announcements
Check out our newest addition to the community, the Cloudera Data Analytics (CDA) group hub.

DROP FUNCTION IF EXISTS udf_... fails with "function udf_... dows not exists"

Explorer

hi

In our application (java code) we're running:

DROP FUNCTION IF EXISTS udf_for_STORE_AGENT_VISIT

and we still get:

2019-06-26 13:49:25,683 ERROR org.apache.hadoop.hive.ql.exec.Task: [HiveServer2-Background-Pool: Thread-6397]: FAILED: error during drop function: org.apache.hadoop.hive.ql.metadata.HiveException: NoSuchObjectException(message:Function udf_for_STORE_AGENT_VISIT does not exist)

 

shouldn't the error be skipped if we have the "IF EXISTS" in the command?

cluster is CDH 5.16.1

 

Thanks

Doron

2 REPLIES 2

Guru
@doronve,

Have you tried from beeline and still the same error?

Please also suggest the version of JDBC driver that you are using and if it is Cloudera Hive JDBC driver?

Cheers
Eric

Explorer
thanks for the response.
the error occured from java - but not from hive cli (and I did not check beelonw)
recently we moved from Oracle JDK to OpenJDK - could this be an issue?
for now I've added hive.exec.drop.ignorenonexistent and it seems to help
Take a Tour of the Community
Don't have an account?
Your experience may be limited. Sign in to explore more.