Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 11-03-2011, 09:01 AM   #1 (permalink)
learner2011
 
Join Date: Mar 2011
Posts: 115
ashwinr87 is on a distinguished road
Default Persisting data into multiple tables at the same time

In my iPAD Application, I have 6 UITableViews and to load data for those views, I call 6 different webservices. Each Table view has its own database table/entity.

My operation for each of the tableview is that I would call a webservice using NSURLConnection and then parse the resulting XML using NSXMLParser and persist the data into the SQLite database using
Code:
[managedObjectContext save:&error];
command.

I would like to know if there is a way I would be able to persist data into multiple tables in SQLite at the same time.
ashwinr87 is offline   Reply With Quote
Old 11-03-2011, 09:31 AM   #2 (permalink)
Emphasizing Fundamentals
 
BrianSlick's Avatar
 
Join Date: Jul 2009
Location: NoVA / DC Area
Age: 36
Posts: 7,990
BrianSlick has a spectacular aura about
Default

If you are using Core Data, then you need to ignore the fact that it is using SQLite. Things will go a lot smoother that way.
__________________
BriTer Ideas LLC - Professional iOS App Development. Available for hire.

SlickShopper 2 | Free NSLog utility | Leave a PayPal donation.

Are you a newbie? Things you should read:
Definitive Guide To Properties | UITableView Series | Guide To Troubleshooting | Model Object Overview

Do you sit at a desk all day? Walk instead! Follow along with my treadmill desk adventures.
BrianSlick is offline   Reply With Quote
Old 11-03-2011, 09:49 AM   #3 (permalink)
learner2011
 
Join Date: Mar 2011
Posts: 115
ashwinr87 is on a distinguished road
Default

thank you for the reply.. I am using core data.. what I meant to ask was that, is core data persistence possible for multiple entities at the same time?

Quote:
Originally Posted by BrianSlick View Post
If you are using Core Data, then you need to ignore the fact that it is using SQLite. Things will go a lot smoother that way.
ashwinr87 is offline   Reply With Quote
Old 11-03-2011, 10:04 AM   #4 (permalink)
Emphasizing Fundamentals
 
BrianSlick's Avatar
 
Join Date: Jul 2009
Location: NoVA / DC Area
Age: 36
Posts: 7,990
BrianSlick has a spectacular aura about
Default

There are techniques that you need to employ for multithreading. Google should turn up everything you need.
__________________
BriTer Ideas LLC - Professional iOS App Development. Available for hire.

SlickShopper 2 | Free NSLog utility | Leave a PayPal donation.

Are you a newbie? Things you should read:
Definitive Guide To Properties | UITableView Series | Guide To Troubleshooting | Model Object Overview

Do you sit at a desk all day? Walk instead! Follow along with my treadmill desk adventures.
BrianSlick is offline   Reply With Quote
Old 11-03-2011, 10:07 AM   #5 (permalink)
learner2011
 
Join Date: Mar 2011
Posts: 115
ashwinr87 is on a distinguished road
Default

thank you..

Quote:
Originally Posted by BrianSlick View Post
There are techniques that you need to employ for multithreading. Google should turn up everything you need.
ashwinr87 is offline   Reply With Quote
Old 11-03-2011, 11:38 AM   #6 (permalink)
Registered Member
 
temi's Avatar
 
Join Date: Oct 2011
Posts: 47
temi is on a distinguished road
Default

If you persist the data for one entity, as long as you are using the same entity across all table views, the data will modified. All you need is to call [table reloadData] on the Table Views you need updated.

Are all these views visible at the same time?
You could also use blocks, here is a blog post from Matt which I read yesterday, that might help.

Using Blocks with Table Views | How to Make iPhone Apps



Quote:
Originally Posted by ashwinr87 View Post
thank you for the reply.. I am using core data.. what I meant to ask was that, is core data persistence possible for multiple entities at the same time?
__________________
Your apps don't have to be ugly because hiring designers are expensive.
Click here to fix that ->iPhone App Designs
temi is offline   Reply With Quote
Reply

Bookmarks

Tags
coredata, ios, sqlite

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 420
18 members and 402 guests
7twenty7, Alex-alex, Apptronics RBC, baja_yu, dre, FrankWeller, gwelmarten, ipodphone, jeroenkeij, jleannex55, matador1978, n00b, pbart, reficul, Retouchable, Sami Gh, usernametaken, VinceYuan
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,676
Threads: 94,125
Posts: 402,910
Top Poster: BrianSlick (7,990)
Welcome to our newest member, jleannex55
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 06:18 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0