Core Data is not a relational database

Core Data, according to Core Data Programming Guide, is not a relational database. At the same time, both Core Data and relational database provide searchable and persistent data storage. So, what is the difference?
Relational databases:

  • maintain relations between rows, columns or tables is done by user, options beyond “read” and “write” are very few

Core Data – object graph manager:

  • user can connect object A and B and this connection is kept sync
  • changes in connection trigger notifications and updates
  • handle deletion of objects (cascade or nullify)
  • possible to use without any form of searching – once objects allocated and connected, we can hold onto one of them and walk through everything without needing a fetch request
  • work on objects in memory – can get slow on big amount of data
  • no threading support (need several NSManagedContext instead)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s