摘要: 场景: 数据库版本v1 有一个persion表 数据库版本v2 新增表student 数据库版本v3 persion表新增一个字段 1 package com.example.natedb; 2 3 import android.content.Context... 阅读全文
posted @ 2015-04-07 23:36 nihao1314520 阅读(168) 评论(0) 推荐(0)
摘要: 插入sqlite插入数据的方法 1,execSQL() 直接拼接sql语句 2,insert() 3,compileStatement()预处理这三中方式插入数据相对较快依次是compileStatement ,insert,execSQL插入大量数据是加上事务处理 1 package com... 阅读全文
posted @ 2015-04-07 23:20 nihao1314520 阅读(773) 评论(1) 推荐(0)
摘要: 关系: IntentService继承service区别: IntentService 是一个带有HandlerThread的线程的service,把任务执行完成以后IntentService自动销毁。 Service要手动 调用stopSelf()来销毁。 IntentService 运行... 阅读全文
posted @ 2015-04-07 00:53 nihao1314520 阅读(776) 评论(0) 推荐(0)