Performance issue

Discussion in 'iOS Programming' started by pravara15, Oct 9, 2009.

  1. pravara15 macrumors newbie

    May 14, 2009
    I want to ask which one is faster, accessing values from local database or reading a text file, in IPhone application.:confused:
  2. jnic macrumors 6502a

    Oct 24, 2008
    In general, databases are usually going to win. Check out FMDB for a nice set of iPhone database wrappers.

    If speed is a very important factor then you're best off implementing it both ways and running tests against a realistic data set to see which is best for your particular use case.
  3. firewood macrumors 604

    Jul 29, 2003
    Silicon Valley
    Depends on how you read, how much you read, and whether you need to do any parsing/formatting/data conversion. If you just want a stream of sequential ascii characters, then the text file read probably has much less overhead. but ymmv.

Share This Page