E
E
Eridana2014-02-11 12:51:40
Objective-C
Eridana, 2014-02-11 12:51:40

What is better to use for an iOS application: Core Data or sqlite + ORM?

Hello. I write on iOS quite recently and one question arose. There is an application, it has some data, respectively. There are not many of them - 2 entities, in one there will be 8-20 records maximum, in the second maximum 100, well, 200.
Friends expressed 2 opposite opinions:
1) it is better to use Core Data, tk. faster to program, more convenient to use, everything ready, etc.
2) it is better to create a database with a third-party sqlite program, attach it to the project and use it with any ORM, because it is then available from the outside, it is easier to change, etc.
What do you think is better to use in this case? What are the pros and cons of these methods? I will be very grateful for the answers.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
A
Alexander Gomzyakov, 2014-02-11
@Eridana

Your task, I believe, will be perfectly solved by means of both ORM and Core Data.
It should be understood that Core Data is not an ORM, but a tool for working with an object graph. You can only compare them very conditionally. If you have already worked with ORM, then using Core Data will be somewhat unusual.
If the deadlines allotted for writing an application do not burn, I recommend that you still get comfortable with Core Data - this is an excellent technology that allows you to completely close the letter M in the MVC abbreviation. In addition to being a native framework that is always "at hand", Core Data is very fast, updated by Apple itself (the likelihood of having to crawl from one ORM to another in the future is lower), and allows you to write very compact and reliable code.
I did not understand what was meant by the availability of sqlite "from outside", and, in principle, I am poorly familiar with ORM solutions. I guess they have their pros and cons.

R
Rockerman, 2014-02-16
@rockerman

I recommend CoreData + MagicalRecords. Practically out of the box, the database will be synchronized via iCloud. A trifle, but nice.

M
Maxim Globak, 2015-12-02
@maximglobak

You can look towards Realm. Very simple syntax and everything is very clear.
p.s. Rumor has it that this thing is faster than CoreData

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question