android - SQLiteDatabase.openDatabase(...) vs getWritableDatabase -


i bundled database app in assets folder. @ first activity, copy database correct location (no problem here).

my question; better use opendatabase (string path, sqlitedatabase.cursorfactory factory, int flags) or use getwritabledatabase method of sqliteopenhelper class?

which more efficient? i'm accustomed using getwritabledatabase method, requires passing of context, feel can without since don't need onupgrade or oncreate function of sqliteopenhelper.

getwritabledatabase sqliteopenhelper's way of opening databases.

if not need sqliteopenhelper, not need call getwritabledatabase either.


Comments

Popular posts from this blog

objective c - Can't build GCM with Protobuf in Xcode -

ember.js - EmberJS Model find not up-to-date with underlying store -

javascript - jQuery iScroll clickable list elements while retaining scroll? -