当前位置:网站首页>Android uses sqliteopenhelper to flash back
Android uses sqliteopenhelper to flash back
2022-07-04 18:10:00 【Blue static cloud】
problem :
I'm sure I'm right , however app Just keep dodging
Try :
Delete app, reinstall
Example :
@Override
public void onCreate(SQLiteDatabase db) {
// If there is group surface , Then delete the table
String drop_sql = "DROP TABLE IF EXISTS " + CHAT_GROUP + ";";
db.execSQL(drop_sql);
// establish group surface
String create_sql = "CREATE TABLE IF NOT EXISTS " + CHAT_GROUP + "("
+ "id INTEGER PRIMARY KEY AUTOINCREMENT,"
+ "group_id VARCHAR NOT NULL,"
+ "chat_type INTEGER DEFAULT NULL"
+ ");";
db.execSQL(create_sql);
}
Add a new field id, Rerun fetch id Print , Flash back
String sql = String.format("select id,group_id,update_time" +
" from %s where %s;", CHAT_GROUP, condition);
onCreate Timing of invocation
边栏推荐
- With an estimated value of 90billion, the IPO of super chip is coming
- shell脚本的替换功能实现
- 7 RSA Cryptosystem
- 【209】go语言的学习思想
- What are cache penetration, cache breakdown, and cache avalanche
- 通过事件绑定实现动画效果
- Set the transparent hidden taskbar and full screen display of the form
- [HCIA continuous update] WLAN overview and basic concepts
- 【Hot100】31. 下一个排列
- Win32 API access route encrypted web pages
猜你喜欢
【华为HCIA持续更新】SDN与FVC
Rainfall warning broadcast automatic data platform bwii broadcast warning monitor
How to test MDM products
“在越南,钱就像躺在街上”
Just today, four experts from HSBC gathered to discuss the problems of bank core system transformation, migration and reconstruction
创业两年,一家小VC的自我反思
Easy to use map visualization
Interpretation of data security governance capability evaluation framework 2.0, the fourth batch of DSG evaluation collection
78 year old professor Huake impacts the IPO, and Fengnian capital is expected to reap dozens of times the return
I wrote a learning and practice tutorial for beginners!
随机推荐
2022年DCMM认证全国各地补贴政策汇总
Solve the El input input box For number number input problem, this method can also be used to replace the problem of removing the arrow after type= "number"
What are cache penetration, cache breakdown, and cache avalanche
The company needs to be monitored. How do ZABBIX and Prometheus choose? That's the right choice!
The money circle boss, who is richer than Li Ka Shing, has just bought a building in Saudi Arabia
Ks007 realizes personal blog system based on JSP
就在今天丨汇丰4位专家齐聚,共讨银行核心系统改造、迁移、重构难题
Zhijieyun - meta universe comprehensive solution service provider
2022 national CMMI certification subsidy policy | Changxu consulting
[HCIA continuous update] network management and operation and maintenance
ARTS_ twenty million two hundred and twenty thousand six hundred and twenty-eight
[daily question] 556 Next bigger element III
蓝桥:合根植物
[Huawei HCIA continuous update] SDN and FVC
中断的顶半部和底半部介绍以及实现方式(tasklet 和 工作队列)
要上市的威马,依然给不了百度信心
Face_recognition人脸识别之考勤统计
如何进行MDM的产品测试
【210】PHP 定界符的用法
【Proteus仿真】基于VSM 串口printf调试输出示例