Confused with a basic idea
Hi,
I am confused with a basic idea.
I have a database and I want to load it and use it in my application.
Application uses navigation controller.
The problem is, when and where should I load the values from the database ?
in application delegate or rootviewcontroller ?
If I do it in rootviewcontroller, everytime I move between different tableviews, the variables get released and the database is loaded again and again.
If I do it in appDelegate, I dont know how to pass the values to the rootviewcontroller.
I want to read the database only once for this whole application.
How can I solve this problem?
How do ppl normally work with databases (i.e, when and where do they read from databases) ?
Thanks for replying.
p.s. Is my question not clear ?
|