Ok, So the samples are a great guide and has helped me to better update a new table, but still having same issue the oldVersion is always the old version it never gets updated!!!
Why is this happening? The OnUpdate function gets called once in a while and my database tries to update when it shouldn't and messes up my data... :( I can check for column count and know that I don't need to update but this is not a great solution... it's going to hunt me on the future... Please help!? Where or how do we tell the SQLiteOpenHelper class that we are a new version now..? It seems that is not getting updated... : ( Thanks! -Moto! On Nov 8, 5:08 pm, Moto <[email protected]> wrote: > Great!! > Thanks guys I really appreciate this! This links are exactly what I > needed! > > Moto! :) > > On Nov 8, 2:32 pm, Dianne Hackborn <[email protected]> wrote: > > > Here's another example, the system settings provider: > > >http://android.git.kernel.org/?p=platform/frameworks/base.git;a=blob;...<http://android.git.kernel.org/?p=platform/frameworks/base.git;a=blob;...> > > > On Sun, Nov 8, 2009 at 10:59 AM, Mark Murphy <[email protected]>wrote: > > > > Moto wrote: > > > > No one had to do a database update? > > > > Database updates work just fine, at least as of Android 1.5, when I last > > > tried them. > > > > To see a database update in action, visit: > > > >http://commonsware.com/AndTutorials > > > > Scroll down, click on the Source Code link, and grab the ZIP file for > > > the answers to the tutorials. The 15-Perms/LunchList project has a > > > working example of onUpdate() replacing a prior version of a table > > > schema. It's a bit elaborate -- ALTER TABLE would be a better choice > > > here -- but I wanted to demonstrate the use of temp tables. > > > > -- > > > Mark Murphy (a Commons Guy) > > >http://commonsware.com|http://twitter.com/commonsguy > > > > _Beginning Android_ from Apress Now Available! > > > > -- > > > You received this message because you are subscribed to the Google > > > Groups "Android Developers" group. > > > To post to this group, send email to [email protected] > > > To unsubscribe from this group, send email to > > > [email protected]<android-developers%[email protected]> > > > For more options, visit this group at > > >http://groups.google.com/group/android-developers?hl=en > > > -- > > Dianne Hackborn > > Android framework engineer > > [email protected] > > > Note: please don't send private questions to me, as I don't have time to > > provide private support, and so won't reply to such e-mails. All such > > questions should be posted on public forums, where I and others can see and > > answer them. > > -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

