-
Notifications
You must be signed in to change notification settings - Fork 417
Open
Labels
Description
If you're a Windows 10 user, you may need to set permissions for the folder holding the code and data for the book. If you don't, you may see an error similar to this:
ERROR: could not open file "C:\YourDirectory\us_counties_2010.csv" for reading: Permission denied
HINT: COPY FROM instructs the PostgreSQL server process to read a file. You may want a client-side facility such as psql's \copy.
SQL state: 42501
To correct this, follow the directions in the note on page xxvii of the Introduction (Practical SQL 1st edition), in the section "Using the Book's Code Examples":
After downloading data, Windows users might need to provide permission for the
database to read files. To do so, right-click the folder containing the code and data,
select Properties, and click the Security tab. Click Edit, then Add. Type the name
Everyone into the object names box and click OK. Highlight Everyone in the user
list, select all boxes under Allow, and then click Apply and OK.