<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Creating java UDF for Spark SQL in Get Started Discussions</title>
    <link>https://community.databricks.com/t5/get-started-discussions/creating-java-udf-for-spark-sql/m-p/49984#M1652</link>
    <description>&lt;P&gt;Hello,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have created a sample java UDF which masks few characters of a string. However I facing couple of issues when uploading and using it.&lt;BR /&gt;&lt;BR /&gt;First I could only import it, which for now is OK. But when do the following,&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;create&lt;/SPAN&gt; &lt;SPAN&gt;function&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;udf_mask&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;as&lt;/SPAN&gt; &lt;SPAN&gt;'baffleCrypto'&lt;/SPAN&gt; &lt;SPAN&gt;using&lt;/SPAN&gt;&lt;SPAN&gt; jar &lt;/SPAN&gt;&lt;SPAN&gt;'/Workspace/Users/sumandra@baffle.io/baffle-databricks-udf-1.0-SNAPSHOT.jar'&amp;nbsp;&lt;BR /&gt;Throws an error&amp;nbsp;&lt;BR /&gt;[NOT_SUPPORTED_WITH_DB_SQL] CREATE FUNCTION is not supported on a SQL warehouse.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Is there an example on how to load a jar and then use it as external function. I followed the this guide&amp;nbsp;&lt;BR /&gt;&lt;A href="https://docs.databricks.com/en/sql/language-manual/sql-ref-syntax-ddl-create-function.html" target="_blank"&gt;https://docs.databricks.com/en/sql/language-manual/sql-ref-syntax-ddl-create-function.html&lt;/A&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Even cut-n-paste errors out.&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;Any ideas?&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Fri, 27 Oct 2023 08:44:11 GMT</pubDate>
    <dc:creator>sm1274</dc:creator>
    <dc:date>2023-10-27T08:44:11Z</dc:date>
    <item>
      <title>Creating java UDF for Spark SQL</title>
      <link>https://community.databricks.com/t5/get-started-discussions/creating-java-udf-for-spark-sql/m-p/49984#M1652</link>
      <description>&lt;P&gt;Hello,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have created a sample java UDF which masks few characters of a string. However I facing couple of issues when uploading and using it.&lt;BR /&gt;&lt;BR /&gt;First I could only import it, which for now is OK. But when do the following,&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;create&lt;/SPAN&gt; &lt;SPAN&gt;function&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;udf_mask&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;as&lt;/SPAN&gt; &lt;SPAN&gt;'baffleCrypto'&lt;/SPAN&gt; &lt;SPAN&gt;using&lt;/SPAN&gt;&lt;SPAN&gt; jar &lt;/SPAN&gt;&lt;SPAN&gt;'/Workspace/Users/sumandra@baffle.io/baffle-databricks-udf-1.0-SNAPSHOT.jar'&amp;nbsp;&lt;BR /&gt;Throws an error&amp;nbsp;&lt;BR /&gt;[NOT_SUPPORTED_WITH_DB_SQL] CREATE FUNCTION is not supported on a SQL warehouse.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Is there an example on how to load a jar and then use it as external function. I followed the this guide&amp;nbsp;&lt;BR /&gt;&lt;A href="https://docs.databricks.com/en/sql/language-manual/sql-ref-syntax-ddl-create-function.html" target="_blank"&gt;https://docs.databricks.com/en/sql/language-manual/sql-ref-syntax-ddl-create-function.html&lt;/A&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Even cut-n-paste errors out.&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;Any ideas?&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 27 Oct 2023 08:44:11 GMT</pubDate>
      <guid>https://community.databricks.com/t5/get-started-discussions/creating-java-udf-for-spark-sql/m-p/49984#M1652</guid>
      <dc:creator>sm1274</dc:creator>
      <dc:date>2023-10-27T08:44:11Z</dc:date>
    </item>
  </channel>
</rss>

