mirror of
https://github.com/groue/GRDB.swift
synced 2026-11-25 04:07:47 +00:00
README.md
This commit is contained in:
1 parent
f447d7f423
commit
3dbf92bb58
1 file changed
+3
-3
@@ -52,11 +52,11 @@ There are already great Swift database libraries. To name a few: [FMDB](https://
|
||||
|
||||
GRBD also addresses your database needs, with a few improvements. **Indulge yourself and let GRDB run the extra mile for you:**
|
||||
|
||||
1. **Great support for SQL**. Other libraries make you feel dirty when you use raw SQL, or leave you naked when you have to turn database data into application values and objects. *GRDB welcomes your SQL skills, and you will feel it.* See the [SQL API](#sqlite-api).
|
||||
1. **Great SQL support**. Other libraries make you feel dirty when you use raw SQL, or leave you naked when you have to turn database data into application values and objects. *GRDB welcomes your SQL skills, and you will feel it.* See the [SQL API](#sqlite-api).
|
||||
|
||||
2. **Great error handling**. While FMDB makes it easy to overlook errors, SQLite.swift treats your local database as if it was some dangerous poison downloaded from Internet. *GRDB won't let any error go, and yet doesn't force you to handle errors that simply shouldn't happen.* See [error handling](#error-handling) for more information.
|
||||
2. **Sensible error handling**. While FMDB makes it easy to overlook errors, SQLite.swift treats your local database as if it was some dangerous poison downloaded from Internet. *GRDB won't let any error go, and yet doesn't force you to handle errors that simply shouldn't happen.* See [error handling](#error-handling) for more information.
|
||||
|
||||
3. **Great records**. Nobody wants to deal with raw SQL rows all day long. FMDB and SQLite.swift won't help you converting them to and from Swift structs or classes. FMDB has [marcoarment/FCModel](https://github.com/marcoarment/FCModel), but it relies on Key-Value-Observing - which does not fit very well with Swift. Core Data and Realm objects are a pain to use in a multi-threaded environment. *GRDB provides ready-made Swift protocols that turn your structs and classes into records that you can freely fetch and store in the database.* See [records](#records) and the [query interface](#the-query-interface).
|
||||
3. **Flexible Records**. Nobody wants to deal with raw SQL rows all day long. FMDB and SQLite.swift won't help you converting them to and from Swift structs or classes. FMDB has [marcoarment/FCModel](https://github.com/marcoarment/FCModel), but it relies on Key-Value-Observing - which does not fit very well with Swift. Core Data and Realm objects are a pain to use in a multi-threaded environment. *GRDB provides ready-made Swift protocols that turn your custom structs and classes into records that you can freely fetch and store in the database.* See [records](#records) and the [query interface](#the-query-interface).
|
||||
|
||||
4. **Threading confidence**. Core Data is quite error-prone as soon as your application leaves the trivial zone. SQLite.swift is easy to misuse in a multi-threaded application. Realm prevents sharing records between threads. FMDB has no support for [WAL mode](https://www.sqlite.org/wal.html). *GRDB builds on top of protocol-oriented programming and immutability to provide a sane and efficient threading environment.* See [Four different ways to handle SQLite concurrency](https://medium.com/@gwendal.roue/four-different-ways-to-handle-sqlite-concurrency-db3bcc74d00e) and [How to build an iOS application with SQLite and GRDB.swift](https://medium.com/@gwendal.roue/how-to-build-an-ios-application-with-sqlite-and-grdb-swift-d023a06c29b3).
|
||||
|
||||
|
||||
Reference in new issue
Block a user