There are two related errors:
Unknown type name 'sqlite3'
And:
Use of undeclared identifier 'sqlite3'
If you receive either of those for SQLite references, you can import sqlite3.h
to resolve them:
#import <sqlite3.h>
If you neglect to link to the libsqlite3.0.dylib
under your target's "Linked Frameworks and Libraries" settings, you may also receive errors like so:
Undefined symbols for architecture i386: "_sqlite3_open", referenced from: -[ViewController openDatabase] in ViewController.o "_sqlite3_close", referenced from: -[ViewController closeDatabase] in ViewController.o
If you receive errors like that, then you can go to your "Target" settings and add libsqlite3.0.dylib
to the list of "Linked Frameworks and Libraries" (see Project Editor Help: Linking to a library or framework).