Hanny
Hanny

Reputation: 2159

How to preload data into a database for iOS?

I'm creating an app that manages mileage. There are pre-set miles for each route (there are 28 locations with routes between each, the mileage is set for each).

I am trying to 'preload' a database table with those routes/mileages so that when the user tracks a new route they've gone (say point A to point B) the app can easily figure out how many miles the user traveled with a quick query.

I've done website development and am familiar with mySQL - but there are some GUI's that I use to preload that data (phpmyadmin); there doesn't seem to be anything similar with the iOS that I can find so I can preload the mileage data into a table (entity?) so I can work on creating the interface to work with that data.

How should I go about achieving this? I am hoping to use core data to achieve this if possible - although SQLite seems like another options some have mentioned. But even others mentioned just holding that data in an array. Being so new to iOS programming - I'm just looking for a solid way to accomplish a pre-loaded database table.

Upvotes: 3

Views: 2213

Answers (1)

Hanny
Hanny

Reputation: 2159

Per the comment from Aaron Brager - using this tutorial I have went with Core Data

http://www.raywenderlich.com/12170/core-data-tutorial-how-to-preloadimport-existing-data-updated

Upvotes: 4

Related Questions