`
flycomos.lee
  • 浏览: 276694 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

SQLite : column '_id' does not exist

 
阅读更多

错误: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.eoeAndroid.SQLite/com.eoeAndroid.SQLite.ActivityMain}: java.lang.IllegalArgumentException: column '_id' does not exist

解决:关于这一部分,必须注意sqlite的主键命名,由于simpleCursorAdapter的方法只识别_id,所以,当你用到sqlite的simpleCursorAdapter时,必须把数据表的主键命名为_id。否则就会出现java.lang.IllegalArgumentException: column '_id' does not exist 错误。

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics