Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Applies to:
Databricks Runtime
Calls a method with reflection.
Syntax
java_method(class, method [, arg1 [, ...] ] )
Arguments
class: ASTRINGliteral specifying the java class.method: ASTRINGliteral specifying the java method.argn: An expression with a type appropriate for the selected method.
Returns
A STRING.
Examples
> SELECT java_method('java.util.UUID', 'randomUUID');
c33fb387-8500-4bfa-81d2-6e0e3e930df2
> SELECT java_method('java.util.UUID', 'fromString', 'a5cf6c42-0c85-418f-af6c-3e4e5b1328f2');
A5cf6c42-0c85-418f-af6c-3e4e5b1328f2