<?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 Spark sql execution for SPN fails with mwc token error in Data Engineering</title>
    <link>https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-sql-execution-for-SPN-fails-with-mwc-token-error/m-p/4824318#M12304</link>
    <description>&lt;P&gt;Is anyone else getting mwc token error on spark.sql execution with SPN accounts? SPN has contributor permission on the workspaces and the query refers to shortcut. Any ideas what can cause this?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Gayatri&lt;/P&gt;</description>
    <pubDate>Fri, 12 Sep 2025 08:39:31 GMT</pubDate>
    <dc:creator>gaya3krishnan86</dc:creator>
    <dc:date>2025-09-12T08:39:31Z</dc:date>
    <item>
      <title>Spark sql execution for SPN fails with mwc token error</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-sql-execution-for-SPN-fails-with-mwc-token-error/m-p/4824318#M12304</link>
      <description>&lt;P&gt;Is anyone else getting mwc token error on spark.sql execution with SPN accounts? SPN has contributor permission on the workspaces and the query refers to shortcut. Any ideas what can cause this?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Gayatri&lt;/P&gt;</description>
      <pubDate>Fri, 12 Sep 2025 08:39:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-sql-execution-for-SPN-fails-with-mwc-token-error/m-p/4824318#M12304</guid>
      <dc:creator>gaya3krishnan86</dc:creator>
      <dc:date>2025-09-12T08:39:31Z</dc:date>
    </item>
    <item>
      <title>Re: Spark sql execution for SPN fails with mwc token error</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-sql-execution-for-SPN-fails-with-mwc-token-error/m-p/4824540#M12309</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/849562"&gt;@gaya3krishnan86&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P data-start="172" data-end="651"&gt;Thanks for posting in Microsoft Fabric Community.&lt;/P&gt;
&lt;P data-start="172" data-end="651"&gt;The&amp;nbsp;mwc token error&amp;nbsp;when executing&amp;nbsp;spark.sql&amp;nbsp;with Service Principal accounts is usually tied to authentication and token handling. Even if the SPN has Contributor permissions on the workspace, it also needs the right data permissions&amp;nbsp;on the underlying storage used by the shortcut. Please make sure the SPN is properly added as an identity in the Fabric workspace and can access the referenced data source.&lt;/P&gt;
&lt;P data-start="172" data-end="651"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P data-start="653" data-end="849"&gt;From the behavior you described, since this involves a shortcut, testing a direct query on a Lakehouse or Warehouse table without the shortcut can help isolate if the issue is shortcut-specific.&lt;/P&gt;
&lt;P data-start="653" data-end="849"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P data-start="653" data-end="849"&gt;Similar issues have been reported when running Spark SQL queries. Restarting the kernel can sometimes result in a “capacity limit exceeded” exception, indicating that session or capacity availability can contribute to the error:&amp;nbsp;&lt;A href="https://community.fabric.microsoft.com/t5/Fabric-platform/Spark-SQL-error-MetaException-message-Unable-to-fetch-mwc-token/m-p/4058008/highlight/true#M8850" target="_blank"&gt;Solved: Re: Spark SQL error: MetaException(message: Unable... - Microsoft Fabric Community&lt;/A&gt;&lt;/P&gt;
&lt;P data-start="653" data-end="849"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P data-start="851" data-end="1218"&gt;There have also been cases where Spark SQL jobs in Fabric returned&amp;nbsp;mwc token&amp;nbsp;errors due to regional outages or bugs in the Spark engine. These incidents were intermittent and region-specific, and in some cases the issue resolved on retry.&lt;/P&gt;
&lt;P data-start="1220" data-end="1251"&gt;For reference, you can check:&amp;nbsp;&lt;A href="https://community.fabric.microsoft.com/t5/Fabric-platform/Spark-SQL-error-MetaException-message-Unable-to-fetch-mwc-token/m-p/4103509/highlight/true#M9072" target="_blank"&gt;Solved: Re: Spark SQL error: MetaException(message: Unable... - Microsoft Fabric Community&lt;/A&gt;&lt;/P&gt;
&lt;P data-start="1220" data-end="1251"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps. Please reach out for further assistance.&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;
&lt;P data-start="1220" data-end="1251"&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 12 Sep 2025 12:28:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-sql-execution-for-SPN-fails-with-mwc-token-error/m-p/4824540#M12309</guid>
      <dc:creator>v-veshwara-msft</dc:creator>
      <dc:date>2025-09-12T12:28:20Z</dc:date>
    </item>
    <item>
      <title>Re: Spark sql execution for SPN fails with mwc token error</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-sql-execution-for-SPN-fails-with-mwc-token-error/m-p/4824910#M12319</link>
      <description>&lt;P&gt;It looks like it fails for a named user too all of sudden but worked fine with workspace identity at the same time. Seems like some intermittent issue.&lt;/P&gt;</description>
      <pubDate>Fri, 12 Sep 2025 23:44:42 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-sql-execution-for-SPN-fails-with-mwc-token-error/m-p/4824910#M12319</guid>
      <dc:creator>gaya3krishnan86</dc:creator>
      <dc:date>2025-09-12T23:44:42Z</dc:date>
    </item>
    <item>
      <title>Re: Spark sql execution for SPN fails with mwc token error</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-sql-execution-for-SPN-fails-with-mwc-token-error/m-p/4826129#M12335</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/849562"&gt;@gaya3krishnan86&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;Thanks for confirming this. Since it also fails for a named user but works with the workspace identity, it appears to be an intermittent platform issue.&lt;/P&gt;
&lt;P&gt;If you need further assistance, please reach out.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Sep 2025 09:12:01 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-sql-execution-for-SPN-fails-with-mwc-token-error/m-p/4826129#M12335</guid>
      <dc:creator>v-veshwara-msft</dc:creator>
      <dc:date>2025-09-15T09:12:01Z</dc:date>
    </item>
  </channel>
</rss>

