Forums

Read csv from local machine

Hi, I have a python code in pythonanywhere which should import csv file from the local machine directly and do some analysis. But its not working and giving the following error. Code is simple read.csv..... NOTE: I dont want to upload the csv in pythonanywhere and then use, Because my ultimate goal is that I will allow user to read their respective csv data from local machine by using a browser button available in my html page which is based on python and Django. Please let me know your thought. Thanks in Advance!

FileNotFoundError at /segmentation File b'E:\Study\Python Study\Data\Bank_data_sample_big.csv' does not exist

Regards, Soumya

Code that is running on our servers only has access to files that are stored on those servers, so you'll need to upload the file somehow if you want your code to be able to access it.