Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

iOS iOS Foundations Core Data Fetching Data: Part 1

Revanth Garlapati
Revanth Garlapati
2,122 Points

Unable to find the PunsData.sqlite database

After viewing the fetching Data tutorial, I was able to visualize the contents of the database in tableview by running the code supplied with this tutorial. However, I unable to locate this database file in the suggested folder, i.e.: /Library/Applicationsupport/iphonesimulator/version#SDK/Applications/Documents

I am sure that the database is being created somewhere, as I am able to visualize it in table view of the application. And also I tried to unhide all files in the relevant folder, but to no avail. Can anyone please suggest me what I am missing?

2 Answers

Amit Bijlani
STAFF
Amit Bijlani
Treehouse Guest Teacher

Try this: ~/Library/Application Support/iPhone Simulator/version number/Applications/unique identifier/Documents

Revanth Garlapati
Revanth Garlapati
2,122 Points

Hi Amit, thanks a lot for your response. Problem solved!

Thanks Revanth

You can NSLog the path out from your app, copy, go to Finder, command+shift+G, and paste it in. Do this while the app is still running.

This can also be done in the Terminal. Copy, and in the Terminal do cd <paste in the path you just copied> and then open . (read: open[space][dot]).

Revanth Garlapati
Revanth Garlapati
2,122 Points
    Hi John, thanks a lot for your response. Problem solved.

-Revanth