iPhone Programmatically
iPhone Programmatically

Reputation: 1227

Fetch data from JSON server and automatically store in sqlite

I want to fetch data from JSON and store it automatically to sqlite whatever updated on server automatically updates to database whenever program runs. Can anyone help me out in it. And if my question is not sufficient to answer please ask anything required.

Thanks in advance.

Upvotes: 1

Views: 1782

Answers (4)

Pushpak Narasimhan
Pushpak Narasimhan

Reputation: 454

If your supporting iOS 5+ then JSON is added for you by default and can use it using the method given here and after getting the dictionary of objects , you can follow the normal procedure of adding them to sqlite or use core data as said by @Paras Joshi.

Upvotes: 0

Jon Deokule
Jon Deokule

Reputation: 1646

I would look into the RestKit framework. It takes care of the low-level API calls, object mapping, SQLite persistence, etc. It's well documented and maintained.

Upvotes: 1

fannheyward
fannheyward

Reputation: 19277

Download JSON data with AFNetworking and decode with JSONKit, then you can save to SQLite with this wrapper FMDB.

Upvotes: 0

Bernat
Bernat

Reputation: 1556

You can start here http://www.raywenderlich.com/5492/working-with-json-in-ios-5

After reading this, you can user this Class, https://github.com/AFNetworking/AFNetworking. It's easy and usefull!

Upvotes: 0

Related Questions