• data1是字符串?需要加上引号


    07-22 15:55:29.832: E/AndroidRuntime(23914): FATAL EXCEPTION: main
    07-22 15:55:29.832: E/AndroidRuntime(23914): android.database.sqlite.SQLiteException: bind or column index out of range: handle 0x11ba958
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:180)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:136)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at android.content.ContentProviderProxy.query(ContentProviderNative.java:358)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at android.content.ContentResolver.query(ContentResolver.java:311)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at com.txrj.sms.manager.SmsDataManager.getNameByAddress(SmsDataManager.java:139)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at com.txrj.sms.activity.ShowSmsActivity$1.handleMessage(ShowSmsActivity.java:41)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at android.os.Handler.dispatchMessage(Handler.java:99)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at android.os.Looper.loop(Looper.java:137)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at android.app.ActivityThread.main(ActivityThread.java:4517)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at java.lang.reflect.Method.invokeNative(Native Method)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at java.lang.reflect.Method.invoke(Method.java:511)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:993)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:760)
    07-22 15:55:29.832: E/AndroidRuntime(23914):     at dalvik.system.NativeStart.main(Native Method)

     

    07-22 16:01:08.913: E/AndroidRuntime(24385): FATAL EXCEPTION: main
    07-22 16:01:08.913: E/AndroidRuntime(24385): android.database.sqlite.SQLiteException: near ")": syntax error: , while compiling: SELECT DISTINCT display_name FROM view_data_restricted data WHERE (1) AND ((mimetype='?' and data1=?-))  // data1是字符串?需要加上引号
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:180)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:136)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at android.content.ContentProviderProxy.query(ContentProviderNative.java:358)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at android.content.ContentResolver.query(ContentResolver.java:311)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at com.txrj.sms.manager.SmsDataManager.getNameByAddress(SmsDataManager.java:139)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at com.txrj.sms.activity.ShowSmsActivity$1.handleMessage(ShowSmsActivity.java:41)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at android.os.Handler.dispatchMessage(Handler.java:99)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at android.os.Looper.loop(Looper.java:137)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at android.app.ActivityThread.main(ActivityThread.java:4517)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at java.lang.reflect.Method.invokeNative(Native Method)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at java.lang.reflect.Method.invoke(Method.java:511)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:993)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:760)
    07-22 16:01:08.913: E/AndroidRuntime(24385):     at dalvik.system.NativeStart.main(Native Method)

  • 相关阅读:
    焦虑来回走
    去省政府客串
    中国地质大学(北京)招生信息有点坑
    张桂梅校长再获殊荣,实至名归!她的故事值得一看再看……
    行内容转为列内容
    公文写作心得
    钟南山院士亲口说的“如何保持健康长寿
    VMware虚拟机出现“内部错误”如何解决?
    CI框架深入篇(2)一些基础的我之不知道的标准格式
    SQL语句学习记录(三)
  • 原文地址:https://www.cnblogs.com/fengzhblog/p/3207854.html
Copyright © 2020-2023  润新知