{"record":{"id":"bba3468bd4d10656","repo":"prestodb/presto","slug":"function-implementation-missing-bba346","errorCode":"FUNCTION_IMPLEMENTATION_MISSING","errorMessage":"%s not found","messagePattern":"(.+?) not found","errorType":"error_code","errorClass":"PrestoException","httpStatus":null,"severity":"error","filePath":"presto-main-base/src/main/java/com/facebook/presto/metadata/FunctionAndTypeManager.java","lineNumber":1066,"sourceCode":"            boolean nonTypeOnlyCoercion = false;\n            for (int i = 0; i < argumentTypes.size(); i++) {\n                Type expectedType = getType(boundSignature.getArgumentTypes().get(i));\n                if (!isTypeOnlyCoercion(argumentTypes.get(i), expectedType)) {\n                    nonTypeOnlyCoercion = true;\n                    break;\n                }\n            }\n            if (nonTypeOnlyCoercion) {\n                continue;\n            }\n\n            return new SpecializedFunctionKey(candidate, boundVariables.get(), argumentTypes.size());\n        }\n\n        // One final check for magic literal functions.\n        // Magic literal functions are only present in the JAVA_BUILTIN_NAMESPACE function namespace.\n        if (!signature.getName().getCatalogSchemaName().equals(JAVA_BUILTIN_NAMESPACE)) {\n            throw new PrestoException(FUNCTION_IMPLEMENTATION_MISSING, format(\"%s not found\", signature));\n        }\n        return builtInTypeAndFunctionNamespaceManager.doGetSpecializedFunctionKeyForMagicLiteralFunctions(signature, this);\n    }\n\n    public BuiltInPluginFunctionNamespaceManager getBuiltInPluginFunctionNamespaceManager()\n    {\n        return builtInPluginFunctionNamespaceManager;\n    }\n\n    private CatalogSchemaName configureDefaultNamespace(String defaultNamespacePrefixString)\n    {\n        if (!defaultNamespacePrefixString.matches(DEFAULT_NAMESPACE_PREFIX_PATTERN.pattern())) {\n            throw new PrestoException(GENERIC_USER_ERROR, format(\"Default namespace prefix string should be in the form of 'catalog.schema', found: %s\", defaultNamespacePrefixString));\n        }\n        String[] catalogSchemaNameString = defaultNamespacePrefixString.split(\"\\\\.\");\n        return new CatalogSchemaName(catalogSchemaNameString[0], catalogSchemaNameString[1]);\n    }\n","sourceCodeStart":1048,"sourceCodeEnd":1084,"githubUrl":"https://github.com/prestodb/presto/blob/55bb57d202de3b926896fa966c2c4a44c779634e/presto-main-base/src/main/java/com/facebook/presto/metadata/FunctionAndTypeManager.java#L1048-L1084","documentation":"After no candidate in any namespace matches the signature, FunctionAndTypeManager throws FUNCTION_IMPLEMENTATION_MISSING ('<signature> not found') unless the function is a magic literal in JAVA_BUILTIN_NAMESPACE, in which case a last-chance resolution is attempted.","triggerScenarios":"getSpecializedFunctionKey is called with a Signature for which no candidate SqlFunction exists (candidates collection matched nothing), and the name is not a magic literal function.","commonSituations":"Function not installed (plugin missing) on the node specializing the query; function deregistered between planning and execution; typo'd or internal-only signature reaching specialization.","solutions":["Install/enable the plugin that provides the function on all nodes","Verify the function name and namespace in the signature are correct","Rebuild/redeploy the plan after fixing function registration","If it is a magic literal path issue, ensure the signature belongs to the java builtin namespace"],"exampleFix":"// before\nSELECT my_udf(x) -- plugin not deployed to workers, FUNCTION_IMPLEMENTATION_MISSING\n// after\ndeploy the plugin jar to every worker's plugin/ dir and restart, then rerun","handlingStrategy":"try-catch","validationCode":"// verify the plugin providing the function is installed on the node before running queries using it","typeGuard":null,"tryCatchPattern":"try { fam.getSpecializedFunctionKey(sig); } catch (PrestoException e) { if (e.getErrorCode().getCode() == FUNCTION_IMPLEMENTATION_MISSING) { /* report missing function/plugin to user */ } }","preventionTips":["Install required plugin jars on every node","Version-check function availability before shipping SQL","Keep function registration and plans in the same deployment"],"tags":["presto","function-implementation","plugin","specialization"],"backgroundTag":"function-implementation-missing","analyzedSha":"55bb57d202de3b926896fa966c2c4a44c779634e","analyzedAt":"2026-09-04T12:50:26.162Z","contentChangedAt":"2026-09-04T12:50:26.162Z","schemaVersion":2},"datasetVersion":"2026-09-11T21:17:09.523Z"}