<?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 Unable to save file in DBFS in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/31761#M23138</link>
    <description>&lt;P&gt;I have took the azure datasets that are available for practice. I got the 10 days data from that dataset and now I want to save this data into DBFS in csv format. I have facing an error :&lt;/P&gt;&lt;P&gt;" No such file or directory: 'No such file or directory: '/dbfs/tmp/myfolder/mytest.csv'&lt;/P&gt;&lt;P&gt;but on the other hand if I am able to access the path directly from DBFS. This path is correct.&lt;/P&gt;&lt;P&gt;My code :&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;from azureml.opendatasets import NoaaIsdWeather
from datetime import datetime
from dateutil import parser 
from dateutil.relativedelta import relativedelta
&amp;nbsp;
spark.sql('DROP Table if exists mytest')
dbutils.fs.rm("/dbfs/tmp/myfolder",recurse = True)
&amp;nbsp;
basepath = "/dbfs/tmp/myfolder" 
&amp;nbsp;
try:
    dbutils.fs.ls(basepath)
except:
    dbutils.fs.mkdirs(basepath)
else:
   raise Exception("The Folder "+ basepath + " already exist, this notebook will remove in the end")
&amp;nbsp;
dbutils.fs.mkdirs("/dbfs/tmp/myfolder")
&amp;nbsp;
start_date = parser.parse('2020-5-1')
end_date = parser.parse('2020-5-10')
&amp;nbsp;
isd = NoaaIsdWeather(start_date, end_date)
pdf = isd.to_spark_dataframe().toPandas().to_csv("/dbfs/tmp/myfolder/mytest.csv")&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;What should I do ? &lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
    <pubDate>Wed, 14 Sep 2022 08:11:16 GMT</pubDate>
    <dc:creator>learnerbricks</dc:creator>
    <dc:date>2022-09-14T08:11:16Z</dc:date>
    <item>
      <title>Unable to save file in DBFS</title>
      <link>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/31761#M23138</link>
      <description>&lt;P&gt;I have took the azure datasets that are available for practice. I got the 10 days data from that dataset and now I want to save this data into DBFS in csv format. I have facing an error :&lt;/P&gt;&lt;P&gt;" No such file or directory: 'No such file or directory: '/dbfs/tmp/myfolder/mytest.csv'&lt;/P&gt;&lt;P&gt;but on the other hand if I am able to access the path directly from DBFS. This path is correct.&lt;/P&gt;&lt;P&gt;My code :&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;from azureml.opendatasets import NoaaIsdWeather
from datetime import datetime
from dateutil import parser 
from dateutil.relativedelta import relativedelta
&amp;nbsp;
spark.sql('DROP Table if exists mytest')
dbutils.fs.rm("/dbfs/tmp/myfolder",recurse = True)
&amp;nbsp;
basepath = "/dbfs/tmp/myfolder" 
&amp;nbsp;
try:
    dbutils.fs.ls(basepath)
except:
    dbutils.fs.mkdirs(basepath)
else:
   raise Exception("The Folder "+ basepath + " already exist, this notebook will remove in the end")
&amp;nbsp;
dbutils.fs.mkdirs("/dbfs/tmp/myfolder")
&amp;nbsp;
start_date = parser.parse('2020-5-1')
end_date = parser.parse('2020-5-10')
&amp;nbsp;
isd = NoaaIsdWeather(start_date, end_date)
pdf = isd.to_spark_dataframe().toPandas().to_csv("/dbfs/tmp/myfolder/mytest.csv")&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;What should I do ? &lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Wed, 14 Sep 2022 08:11:16 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/31761#M23138</guid>
      <dc:creator>learnerbricks</dc:creator>
      <dc:date>2022-09-14T08:11:16Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to save file in DBFS</title>
      <link>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/31762#M23139</link>
      <description>&lt;P&gt;Hi, post running .mkdirs command, could you please confirm where the .csv file has been copied?&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2022 05:52:22 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/31762#M23139</guid>
      <dc:creator>Debayan</dc:creator>
      <dc:date>2022-09-16T05:52:22Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to save file in DBFS</title>
      <link>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/40021#M27109</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/62672"&gt;@learnerbricks&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;is this post already solved ? how you solved it?&lt;/P&gt;</description>
      <pubDate>Wed, 16 Aug 2023 06:56:41 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/40021#M27109</guid>
      <dc:creator>pardosa</dc:creator>
      <dc:date>2023-08-16T06:56:41Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to save file in DBFS</title>
      <link>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/40081#M27119</link>
      <description>&lt;P&gt;hello, you should really avoid writing data to dfbs.&lt;/P&gt;</description>
      <pubDate>Wed, 16 Aug 2023 15:58:24 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/40081#M27119</guid>
      <dc:creator>youssefmrini</dc:creator>
      <dc:date>2023-08-16T15:58:24Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to save file in DBFS</title>
      <link>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/51979#M29374</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;after some exercise you need to aware folder create in&amp;nbsp;&lt;STRONG&gt;dbutils.fs.mkdirs("/dbfs/tmp/myfolder")&amp;nbsp;&lt;/STRONG&gt;it's created in&amp;nbsp;&lt;STRONG&gt;/dbfs/dbfs/tmp/myfolder&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;if you want to access path &lt;STRONG&gt;&lt;EM&gt;to_csv("/dbfs/tmp/myfolder/mytest.csv")&lt;/EM&gt;&amp;nbsp;&lt;/STRONG&gt;you should created with this script dbutils.fs.mkdirs('&lt;STRONG&gt;&lt;EM&gt;dbfs:&lt;/EM&gt;&lt;/STRONG&gt;/tmp/myfolder)&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 15 Nov 2023 04:34:06 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/unable-to-save-file-in-dbfs/m-p/51979#M29374</guid>
      <dc:creator>pardosa</dc:creator>
      <dc:date>2023-11-15T04:34:06Z</dc:date>
    </item>
  </channel>
</rss>

