<?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 Re: Databricks Runtime 10.4 LTS -  AnalysisException: No such struct field id in 0, 1 after upgrading in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23018#M15858</link>
    <description>&lt;P&gt;@Kaniz Fatma​&amp;nbsp;&lt;/P&gt;&lt;P&gt;Your answer suffices my query. Thanks!&lt;/P&gt;&lt;P&gt;In addition, for fellow developers, I later noticed that these release notes are also available on the home screen of your Databricks workspace.&lt;/P&gt;</description>
    <pubDate>Tue, 26 Apr 2022 18:45:53 GMT</pubDate>
    <dc:creator>Nirupam</dc:creator>
    <dc:date>2022-04-26T18:45:53Z</dc:date>
    <item>
      <title>Databricks Runtime 10.4 LTS -  AnalysisException: No such struct field id in 0, 1 after upgrading</title>
      <link>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23012#M15852</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;We are working to migrate to databricks runtime 10.4 LTS from 9.1 LTS but we're running into weird behavioral issues. Our existing code works up until runtime 10.3 and in 10.4 it stopped working.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;B&gt;Problem:&lt;/B&gt;&lt;/P&gt;&lt;P&gt;We have a nested json file that we are flattening into a spark data frame using the code below:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;adaccountsdf = df.withColumn('Exp_Organizations', F.explode(F.col('organizations.organization')))\
                  .withColumn('Exp_AdAccounts', F.explode(F.col('Exp_Organizations.ad_accounts')))\
                  .select(F.col('Exp_Organizations.id').alias('organizationId'),
                                  F.col('Exp_Organizations.name').alias('organizationName'),
                                  F.col('Exp_AdAccounts.id').alias('adAccountId'),
                                  F.col('Exp_AdAccounts.name').alias('adAccountName'),
                                  F.col('Exp_AdAccounts.timezone').alias('timezone'))&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Now when we query the dataframe it works when we do the following selects (hid results due to confidentiality):&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;display(adaccountsdf.select("*"))
&amp;nbsp;
OR
&amp;nbsp;
display(adaccountsdf)&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="image"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/1943i8157F367D9D56F8F/image-size/large?v=v2&amp;amp;px=999" role="button" title="image" alt="image" /&gt;&lt;/span&gt;When I display the schema of the dataframe we get the following:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;root
 |-- organizationId: string (nullable = true)
 |-- organizationName: string (nullable = true)
 |-- adAccountId: string (nullable = true)
 |-- adAccountName: string (nullable = true)
 |-- timezone: string (nullable = true)&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;so everything looks like it should. The moment we start selecting the last 3 fields(adAccountId, adAccountName and timezone) we get the following error:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="image"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/1940i026E7F413FFBB038/image-size/large?v=v2&amp;amp;px=999" role="button" title="image" alt="image" /&gt;&lt;/span&gt;However when we select a single column it works fine:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="image"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/1950i5624FD8A9CD0F16D/image-size/large?v=v2&amp;amp;px=999" role="button" title="image" alt="image" /&gt;&lt;/span&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does anyone know why this is happening? It's a very strange error that only shows up in databricks runtime 10.4. All previous runtimes incl 10.3, 10.2,10.1 and 9.1 LTS work fine. The issue seems to be caused by using the explode function on an already exploded column in the dataframe. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;B&gt;UPDATE:&lt;/B&gt;&lt;/P&gt;&lt;P&gt;For some reason when I run &lt;B&gt;adaccountsdf.cache() &lt;/B&gt;before I run my select statements the issue disappears. Would still like to know what's causing this issue in runtime 10.4 but not the other ones. &lt;/P&gt;</description>
      <pubDate>Tue, 12 Apr 2022 17:15:02 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23012#M15852</guid>
      <dc:creator>Emiel_Smeenk</dc:creator>
      <dc:date>2022-04-12T17:15:02Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks Runtime 10.4 LTS -  AnalysisException: No such struct field id in 0, 1 after upgrading</title>
      <link>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23014#M15854</link>
      <description>&lt;P&gt;It seems like the issue was miraculously resolved. I did not make any code changes but everything is now running as expected. &lt;/P&gt;&lt;P&gt;Maybe the latest runtime 10.4 fix released on April 19th also resolved this issue unintentionally. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Apr 2022 15:59:22 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23014#M15854</guid>
      <dc:creator>Emiel_Smeenk</dc:creator>
      <dc:date>2022-04-20T15:59:22Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks Runtime 10.4 LTS -  AnalysisException: No such struct field id in 0, 1 after upgrading</title>
      <link>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23015#M15855</link>
      <description>&lt;P&gt;@Emiel Smeenk​&amp;nbsp;&lt;/P&gt;&lt;P&gt;We were facing the same issue and suddenly 2022-Apr-20 onwards it resolved itself.&lt;/P&gt;&lt;P&gt;Question:- Is there any website where I can see/track these "patches"?&lt;/P&gt;&lt;P&gt;Edit: Added Question.&lt;/P&gt;</description>
      <pubDate>Thu, 21 Apr 2022 10:55:47 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23015#M15855</guid>
      <dc:creator>Nirupam</dc:creator>
      <dc:date>2022-04-21T10:55:47Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks Runtime 10.4 LTS -  AnalysisException: No such struct field id in 0, 1 after upgrading</title>
      <link>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23018#M15858</link>
      <description>&lt;P&gt;@Kaniz Fatma​&amp;nbsp;&lt;/P&gt;&lt;P&gt;Your answer suffices my query. Thanks!&lt;/P&gt;&lt;P&gt;In addition, for fellow developers, I later noticed that these release notes are also available on the home screen of your Databricks workspace.&lt;/P&gt;</description>
      <pubDate>Tue, 26 Apr 2022 18:45:53 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23018#M15858</guid>
      <dc:creator>Nirupam</dc:creator>
      <dc:date>2022-04-26T18:45:53Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks Runtime 10.4 LTS -  AnalysisException: No such struct field id in 0, 1 after upgrading</title>
      <link>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23020#M15860</link>
      <description>&lt;P&gt;@Kaniz Fatma​&amp;nbsp;I did not ask the original question. &lt;/P&gt;&lt;P&gt;@Emiel Smeenk​&amp;nbsp;had asked and answered his own question stating that the issue was fixed on its own (probably due to latest patch). &lt;/P&gt;</description>
      <pubDate>Tue, 26 Apr 2022 19:54:28 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23020#M15860</guid>
      <dc:creator>Nirupam</dc:creator>
      <dc:date>2022-04-26T19:54:28Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks Runtime 10.4 LTS -  AnalysisException: No such struct field id in 0, 1 after upgrading</title>
      <link>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23022#M15862</link>
      <description>&lt;P&gt;Issue resolved on its own so selected that as the best answer for this post.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Emiel&lt;/P&gt;</description>
      <pubDate>Tue, 26 Apr 2022 20:16:15 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/databricks-runtime-10-4-lts-analysisexception-no-such-struct/m-p/23022#M15862</guid>
      <dc:creator>Emiel_Smeenk</dc:creator>
      <dc:date>2022-04-26T20:16:15Z</dc:date>
    </item>
  </channel>
</rss>

