<?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: Why am I getting NameError name ' ' is not defined in another cell? in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/38803#M26768</link>
    <description>&lt;P&gt;A variable defined in a particular language environment will be available only in that environment. It will not be available in other environments. Can you confirm?&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/45155"&gt;@Ank&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/85634"&gt;@Morg&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 01 Aug 2023 04:49:20 GMT</pubDate>
    <dc:creator>Tharun-Kumar</dc:creator>
    <dc:date>2023-08-01T04:49:20Z</dc:date>
    <item>
      <title>Why am I getting NameError name ' ' is not defined in another cell?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/33969#M24837</link>
      <description>&lt;P&gt;I defined a dictionary variable Dict, populated it, and print(dict) in the first cell of my notebook. In the next cell, I executed the command print(dict) again. However, this time it gave me an error &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NameError: name 'Dict is not defined&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How can that be? Why am I able to print this variable in one cell, but unable to do so in the next cell?&lt;/P&gt;</description>
      <pubDate>Mon, 22 Aug 2022 23:33:12 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/33969#M24837</guid>
      <dc:creator>Ank</dc:creator>
      <dc:date>2022-08-22T23:33:12Z</dc:date>
    </item>
    <item>
      <title>Re: Why am I getting NameError name ' ' is not defined in another cell?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/38777#M26756</link>
      <description>&lt;P&gt;I am facing the same issue while executing a job currently. Was a cause/solution found for this?&lt;/P&gt;</description>
      <pubDate>Mon, 31 Jul 2023 12:20:54 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/38777#M26756</guid>
      <dc:creator>Morg</dc:creator>
      <dc:date>2023-07-31T12:20:54Z</dc:date>
    </item>
    <item>
      <title>Re: Why am I getting NameError name ' ' is not defined in another cell?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/38802#M26767</link>
      <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/45155"&gt;@Ank&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/85634"&gt;@Morg&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;One possible scenario, when this could happen is the variable (dict) was defined in a python environment and it was called in a scala environment or the vice versa.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2023-08-01 at 10.14.23 AM.png" style="width: 929px;"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/3027i0C68C912C7443966/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2023-08-01 at 10.14.23 AM.png" alt="Screenshot 2023-08-01 at 10.14.23 AM.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Aug 2023 04:48:30 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/38802#M26767</guid>
      <dc:creator>Tharun-Kumar</dc:creator>
      <dc:date>2023-08-01T04:48:30Z</dc:date>
    </item>
    <item>
      <title>Re: Why am I getting NameError name ' ' is not defined in another cell?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/38803#M26768</link>
      <description>&lt;P&gt;A variable defined in a particular language environment will be available only in that environment. It will not be available in other environments. Can you confirm?&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/45155"&gt;@Ank&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/85634"&gt;@Morg&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Aug 2023 04:49:20 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/38803#M26768</guid>
      <dc:creator>Tharun-Kumar</dc:creator>
      <dc:date>2023-08-01T04:49:20Z</dc:date>
    </item>
    <item>
      <title>Re: Why am I getting NameError name ' ' is not defined in another cell?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/39446#M26982</link>
      <description>&lt;P&gt;I can confirm that your answer at least pointed me in the right direction.&lt;BR /&gt;&lt;BR /&gt;It seems my issue wasn't exactly the same as I was instead using the magic pip command to install a notebook scoped package:&lt;BR /&gt;%pip install &amp;lt;some-package&amp;gt;&lt;BR /&gt;&lt;BR /&gt;Anything defined within that command cell seems to be lost so I had to separate this into it's own command before everything else.&lt;BR /&gt;&lt;BR /&gt;Thank you for the help!&lt;/P&gt;</description>
      <pubDate>Wed, 09 Aug 2023 13:19:03 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/39446#M26982</guid>
      <dc:creator>Morg</dc:creator>
      <dc:date>2023-08-09T13:19:03Z</dc:date>
    </item>
    <item>
      <title>Re: Why am I getting NameError name ' ' is not defined in another cell?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/39448#M26984</link>
      <description>&lt;P&gt;Running pip install restarts the interpreter, meaning that any variable defined prior to the pip install is lost, so indeed the solution is so run the pip install first, or better is to add the library you want to installl directly to the cluster configuration&lt;/P&gt;</description>
      <pubDate>Wed, 09 Aug 2023 14:20:58 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-am-i-getting-nameerror-name-is-not-defined-in-another-cell/m-p/39448#M26984</guid>
      <dc:creator>erigaud</dc:creator>
      <dc:date>2023-08-09T14:20:58Z</dc:date>
    </item>
  </channel>
</rss>

