Created
November 26, 2014 17:08
-
-
Save johannfjs/0a17c5e8924df43674a5 to your computer and use it in GitHub Desktop.
ManageOpenHelper
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ManageOpenHelper extends SQLiteOpenHelper { | |
public ManageOpenHelper(Context context) { | |
super(context, Constant.DBname, null, Constant.DBversion); | |
// TODO Auto-generated constructor stub | |
} | |
@Override | |
public void onCreate(SQLiteDatabase db) { | |
// TODO Auto-generated method stub | |
db.execSQL(Constant.CREATE_TABLE_PERSONA); | |
db.execSQL(Constant.CREATE_TABLE_USUARIO); | |
} | |
@Override | |
public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { | |
// TODO Auto-generated method stub | |
db.execSQL(Constant.DROP_TABLE_USUARIO); | |
db.execSQL(Constant.DROP_TABLE_PERSONA); | |
onCreate(db); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment