Book Image

Learning SQLite for iOS

By : Gene Da Rocha
Book Image

Learning SQLite for iOS

By: Gene Da Rocha

Overview of this book

The ability to use SQLite with iOS provides a great opportunity to build amazing apps. Apple's iOS SDK provides native support for SQLite databases. This combination offers the potential to create powerful, data-persistent applications. This book starts with the architecture of SQLite database and introduces you to concepts in SQL . You will find yourself equipped to design your own database system, administer it, and maintain it. Further, you will learn how to operate your SQLite databases smoothly using SQL commands. You will be able to extend the functionality of SQLite by using its vast arsenal of C API calls to build some interesting, exciting, new, and intelligent data-driven applications. Understand how Xcode, HTML5, and Phonegap can be used to build a cross-platform modern app which can benefit from all these technologies - all through creating a complete, customizable application skeleton that you can build on for your own apps.
Table of Contents (15 chapters)
Learning SQLite for iOS
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
Index

Data integrity


Data integrity is very important in maintaining how tables and data relationships are defined and protected. There are four types of integrity: user defined, referential, entity, and domain.

The mastering of data manipulation, database design, development, and administration is key to ensure that applications built using SQLite perform well, and are kept free from data crashes, data corruptions, and security issues.

When a column's datatype is set, it is a form of data integrity. Data integrity can be enhanced by only allowing certain values.

When a mechanism is designed to maintain the primary keys in a table by a unique tuple or row identifier, it is known as entity integrity.

Referential integrity occurs when, for example, two tables are linked by a common column datatype and no new data can be added to one table without being added to the second. Referential integrity ensures that data is cleaned and linked properly.