嗯,我下面有一些代码,但我真的不知道它是如何工作的以及如何填充它。我需要填充大约30,000个元素。
public class DatabaseHelper extends SQLiteOpenHelper {
static final String dbName="demoDB";
static final String quoteTable="Quote";
static final String quoteID="ID";
static final String quoteText="Quote";
static final String viewEmps="ViewEmps";
public DatabaseHelper(Context context) {
super(context, dbName, null,33);
}
public void onCreate(SQLiteDatabase db) {
db.execSQL("CREATE TABLE "+quoteTable+" ("+
quoteID+ " INTEGER PRIMARY KEY , "+
quoteText+ " TEXT)");
}