• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: [Core Data] Improve save performance ?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Core Data] Improve save performance ?


  • Subject: Re: [Core Data] Improve save performance ?
  • From: Eric Morand <email@hidden>
  • Date: Tue, 17 Jan 2006 00:36:05 +0100

I suggest you write a loop around your code so you create and save an
object many times and measure the result of that. I suspect the SQLite
will speed up after the first save.

You're pretty right !!!

I've created a loop of 1000 save and the first one takes 0.5 second whil the 999 next ones were achieved in less than 0.3 second - all of them in 0.3 second, now that's what I like !!!

Still, I have a problem with the first one being so slow. Because when my user submit a new transaction, it is saved to the store alone...and then it takes 0.5 second.
And I can't rely on XML store because there will be thousands of objects in the store.



Eric.


Le 17 janv. 06 à 00:18, Guy English a écrit :

- SQLite : around 0.450 second
- XML : around 0.005 second !!!
Maybe there is something I'm doing wrong when creating my SQLite
persistent store. I thought a SQLite store was faster than XML store.

I haven't timed this kind of stuff myself it's always been fast enough that I haven't bothered.

Ideas ?

Scale. If you're only dealing with one object may be easier to dump out an XML plist for it. The SQLite store may have some initial setup to be done. SQLite will scale much better though so if you're dealing with thousands of objects it'll trounce the XML.

I suggest you write a loop around your code so you create and save an
object many times and measure the result of that. I suspect the SQLite
will speed up after the first save.

Oh - and I assume the stores are on the same disk and you're not
saving the SQLite on your iDisk or something.

Guy
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden

============================================= Automator Ketchup : http://automatorketchup.blogspot.com



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: [Core Data] Improve save performance ?
      • From: Eric Morand <email@hidden>
References: 
 >[Core Data] Improve save performance ? (From: Eric Morand <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: Aurélien Hugelé <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: Eric Morand <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: mmalcolm crawford <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: "Timothy J. Wood" <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: Eric Morand <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: Kay Roepke <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: Eric Morand <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: Scott Ellsworth <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: Eric Morand <email@hidden>)
 >Re: [Core Data] Improve save performance ? (From: Guy English <email@hidden>)

  • Prev by Date: NSProtocolChecker help
  • Next by Date: Re: NSBezierPath containsPoint is buggy?
  • Previous by thread: Re: [Core Data] Improve save performance ?
  • Next by thread: Re: [Core Data] Improve save performance ?
  • Index(es):
    • Date
    • Thread