I am creating an iphone app within XCODE the makes use of an SQLite3 database. I am creating the database programmatically if it does not exist. I am not getting any errors when I run the program.
How can I check the contents of the database to ensure that the data has been inserted correctly into the correct columns? Where does Xcode place the table within my system where I can view it?
The SQLite database will be created in your apps Documents
folder, in the simulator's base directory.
Before Xcode 6, you can check in:
~/Library/Application Support/iPhone Simulator/4.2/Applications/GUID/Documents
There is also a Mac OS X application called SQLiteBrowser that you can use to browse the database your app created.
As of Xcode 6, the new iOS simulator's directory is located here :
~/Library/Developer/CoreSimulator
Ultimately, you can find your app's database under a location like this (Replace UIDs by yours) :
~/Library/Developer/CoreSimulator/Devices/4D2D127A-7103-41B2-872B-2DB891B978A2/data/Containers/Data/Application/0323215C-2B91-47F7-BE81-EB24B4DA7339/Documents/MyApp.sqlite
Source: SO: Xcode 6 iPhone Simulator Application Support Location
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With