<?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: Python open function is unable to detect the file in dbfs in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/python-open-function-is-unable-to-detect-the-file-in-dbfs/m-p/28121#M19954</link>
    <description>&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Hi @billaspiel&lt;/P&gt;
&lt;P&gt;Can you please try by removing the colon ":" ? Here is a documentation on how to read/write the data&lt;/P&gt;
&lt;P&gt;&lt;A href="https://docs.databricks.com/user-guide/dbfs-databricks-file-system.html#access-dbfs-using-local-file-apis" target="test_blank"&gt;https://docs.databricks.com/user-guide/dbfs-databricks-file-system.html#access-dbfs-using-local-file-apis&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;If the issue still occurs, please share the complete statement and also the error message you are getting. Let us know how it goes.&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt; 
&lt;P&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 25 Apr 2019 12:33:44 GMT</pubDate>
    <dc:creator>mathan_pillai</dc:creator>
    <dc:date>2019-04-25T12:33:44Z</dc:date>
    <item>
      <title>Python open function is unable to detect the file in dbfs</title>
      <link>https://community.databricks.com/t5/data-engineering/python-open-function-is-unable-to-detect-the-file-in-dbfs/m-p/28120#M19953</link>
      <description>&lt;P&gt;&lt;/P&gt;
&lt;P&gt; hi ,&lt;/P&gt;
&lt;P&gt;Im a newbie learning spark using databricks , I did some investigation and searched if this questions was been asked earlier in community forum but unable to find anything so .&lt;/P&gt;
&lt;P&gt;1. DBFS is unable to detect the file even though its present in it .&lt;/P&gt;
&lt;P&gt;&lt;I&gt;The issue happens only with below command &lt;/I&gt;&lt;/P&gt;
&lt;P&gt;with open("dbfs:/FileStore/tables/data.txt") as f: &lt;/P&gt;
&lt;P&gt;&lt;I&gt;and not with &lt;/I&gt;&lt;/P&gt;
&lt;P&gt;lines0 = sc.textFile("/FileStore/tables/data.txt"&lt;/P&gt;
&lt;P&gt;Does this mean in databricks notebook we can't use python open function to open a file ? &lt;/P&gt; 
&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 25 Apr 2019 10:54:25 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/python-open-function-is-unable-to-detect-the-file-in-dbfs/m-p/28120#M19953</guid>
      <dc:creator>billaspiel</dc:creator>
      <dc:date>2019-04-25T10:54:25Z</dc:date>
    </item>
    <item>
      <title>Re: Python open function is unable to detect the file in dbfs</title>
      <link>https://community.databricks.com/t5/data-engineering/python-open-function-is-unable-to-detect-the-file-in-dbfs/m-p/28121#M19954</link>
      <description>&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Hi @billaspiel&lt;/P&gt;
&lt;P&gt;Can you please try by removing the colon ":" ? Here is a documentation on how to read/write the data&lt;/P&gt;
&lt;P&gt;&lt;A href="https://docs.databricks.com/user-guide/dbfs-databricks-file-system.html#access-dbfs-using-local-file-apis" target="test_blank"&gt;https://docs.databricks.com/user-guide/dbfs-databricks-file-system.html#access-dbfs-using-local-file-apis&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;If the issue still occurs, please share the complete statement and also the error message you are getting. Let us know how it goes.&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt; 
&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 25 Apr 2019 12:33:44 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/python-open-function-is-unable-to-detect-the-file-in-dbfs/m-p/28121#M19954</guid>
      <dc:creator>mathan_pillai</dc:creator>
      <dc:date>2019-04-25T12:33:44Z</dc:date>
    </item>
    <item>
      <title>Re: Python open function is unable to detect the file in dbfs</title>
      <link>https://community.databricks.com/t5/data-engineering/python-open-function-is-unable-to-detect-the-file-in-dbfs/m-p/28122#M19955</link>
      <description>&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Hi mathan,&lt;/P&gt;
&lt;P&gt;Thanks for the information , in addition to removing colon':' added '/' as well before dbfs which resolved the issue .&lt;/P&gt;
&lt;P&gt;&lt;B&gt;working syntax&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;&lt;B&gt;----------------------&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;with open("&lt;B&gt;/&lt;/B&gt;dbfs&lt;B&gt;/&lt;/B&gt;FileStore/tables/data.txt") as f:&lt;/P&gt; 
&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Apr 2019 07:11:22 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/python-open-function-is-unable-to-detect-the-file-in-dbfs/m-p/28122#M19955</guid>
      <dc:creator>billaspiel</dc:creator>
      <dc:date>2019-04-29T07:11:22Z</dc:date>
    </item>
    <item>
      <title>Re: Python open function is unable to detect the file in dbfs</title>
      <link>https://community.databricks.com/t5/data-engineering/python-open-function-is-unable-to-detect-the-file-in-dbfs/m-p/28123#M19956</link>
      <description>&lt;P&gt;I am having similar issues currently. I can read or access my storage account but when I attempted to read or access the container it told me path not found. I create the container and have full access as an owner. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Mar 2023 21:24:04 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/python-open-function-is-unable-to-detect-the-file-in-dbfs/m-p/28123#M19956</guid>
      <dc:creator>Dflo</dc:creator>
      <dc:date>2023-03-21T21:24:04Z</dc:date>
    </item>
  </channel>
</rss>

