本文介绍了无法启动活动,android.database.sqlite.SQLiteException:没有这样的表,在编译时:SELECT * FROM表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我收到此错误,做第一次这么有任何建议,为什么它是未来,以及如何解决它。
从这个环节我没有得到任何帮助, android.database.sqlite.SQLiteException附近DATABASE_TABLE_NAME语法错误(code:1)在编译organizationSetup

数据库处理程序

 公共类数据库处理器扩展SQLiteOpenHelper {            //所有静态变量
            //数据库版本
            私有静态最终诠释DATABASE_VERSION = 1;            //数据库名称
            私有静态最后弦乐DATABASE_NAME =android_api;            //登录表名
            私有静态最后弦乐TABLE_LOGIN =登录;
            私有静态最后弦乐TABLE_TRACK =跟踪;
            //登录表列名
            私有静态最后弦乐KEY_ID =ID;
            私有静态最后弦乐KEY_NAME =名;
            私有静态最后弦乐KEY_EMAIL =电子邮件;
            私有静态最后弦乐KEY_UID =UID;
            私有静态最后弦乐KEY_CREATED_AT =created_at;
            //跟踪表列名
            私有静态最后弦乐KEY_UIDTRACK =idtrack;
            私有静态最后弦乐KEY_DOCKETNO =docketno;
            私有静态最后弦乐KEY_DEALERNAME =dealername;
            私有静态最后弦乐KEY_CUSTOMERNAME =客户名称;
            私有静态最后弦乐KEY_PCS =PCS;
            私有静态最后弦乐KEY_DELIVERY_STATUS =deliverstatus;
            私有静态最后弦乐KEY_REMARKS =备注;
            私有静态最后弦乐KEY_CREATED_AT_TRACK =created_at_track;            公共数据库处理器(上下文的背景下){
                超(背景下,DATABASE_NAME,空,DATABASE_VERSION);
            }            //创建表
            @覆盖
            公共无效的onCreate(SQLiteDatabase DB){
                字符串CREATE_LOGIN_TABLE =CREATE TABLE+ TABLE_LOGIN +(
                        + KEY_ID +INTEGER PRIMARY KEY,+ KEY_NAME +TEXT
                        + KEY_EMAIL +TEXT独一无二的,+ KEY_UID +TEXT
                        + KEY_CREATED_AT +TEXT+);
                字符串CREATE_TABLE_TRACK =CREATE TABLE+ TABLE_TRACK +(
                        + KEY_UIDTRACK +INTEGER PRIMARY KEY,+ KEY_DOCKETNO
                        +INTEGER PRIMARY KEY,+ KEY_DEALERNAME +TEXT
                        + KEY_CUSTOMERNAME +TEXT+ KEY_PCS
                        +INTEGER PRIMARY KEY,+ KEY_DELIVERY_STATUS +TEXT
                        + KEY_REMARKS +TEXT+ KEY_CREATED_AT_TRACK +TEXT
                        +);
                 db.execSQL(CREATE_LOGIN_TABLE);
                 db.execSQL(CREATE_TABLE_TRACK);
            }            //数据库升级
            @覆盖
            公共无效onUpgrade(SQLiteDatabase分贝,INT oldVersion,诠释静态网页){
                如果存在//删除旧的表
                db.execSQL(DROP TABLE IF EXISTS+ TABLE_LOGIN);
                db.execSQL(DROP TABLE IF EXISTS+ TABLE_TRACK);
                //再次创建表
                的onCreate(DB);
            }            / **
             *存储用户数据库的详细信息
             * * /
            公共无效ADDUSER(字符串名称,字符串电子邮件,UID字符串,字符串created_at){
                SQLiteDatabase分贝= this.getWritableDatabase();                ContentValues​​值=新ContentValues​​();
                values​​.put(KEY_NAME,名); // 名称
                values​​.put(KEY_EMAIL,电子邮件); //电子邮件
                values​​.put(KEY_UID,UID); //电子邮件                //插入行
                db.insert(TABLE_LOGIN,空,价值);
                db.close(); //关闭数据库连接
            }            / **
             *存储AeyeTrack信息数据库
             * * /
            公共无效addAeyeTrack(整数idtrack,整数docketno,
                    字符串dealername,字符串客户名称,整件,
                    字符串deliverstatus,串话,串created_at_track){
                SQLiteDatabase分贝= this.getWritableDatabase();                ContentValues​​值=新ContentValues​​();                values​​.put(KEY_UIDTRACK,idtrack); // idtrack
                values​​.put(KEY_DOCKETNO,docketno); // docketno
                values​​.put(KEY_DEALERNAME,dealername); // dealername
                values​​.put(KEY_CUSTOMERNAME,客户名称); // 顾客姓名
                values​​.put(KEY_PCS,PCS); //件
                values​​.put(KEY_DELIVERY_STATUS,deliverstatus); // deliverstatus
                values​​.put(KEY_REMARKS,备注); //言论
                values​​.put(KEY_CREATED_AT_TRACK,created_at_track); // created_at_track                //插入行
                db.insert(TABLE_TRACK,空,价值);
                db.close(); //关闭数据库连接
            }            / **
             *充分利用数据库​​更新AeyeTrack数据
             * * /
            公共布尔updateAeyeTrack(整数idtrack,整数docketno,
                    字符串dealername,字符串客户名称,整件,
                    字符串deliverstatus,串话,串created_at_track){
                SQLiteDatabase分贝= this.getWritableDatabase();
                ContentValues​​ contentValues​​ =新ContentValues​​();
                contentValues​​.put(KEY_UIDTRACK,idtrack); // idtrack
                contentValues​​.put(KEY_DOCKETNO,docketno); // docketno
                contentValues​​.put(KEY_DEALERNAME,dealername); // dealername
                contentValues​​.put(KEY_CUSTOMERNAME,客户名称); // 顾客姓名
                contentValues​​.put(KEY_PCS,PCS); //件
                contentValues​​.put(KEY_DELIVERY_STATUS,deliverstatus); // deliverstatus
                contentValues​​.put(KEY_REMARKS,备注); //言论
                contentValues​​.put(KEY_CREATED_AT_TRACK,created_at_track); // created_at_track                db.update(跟踪,contentValues​​,idtrack =?,
                        新的String [] {Integer.toString(idtrack)});
                返回true;
            }            / **
             从数据库*前往AeyeTrack数据
             * * /
            公众的HashMap<字符串,字符串> getAeyeTrackDetails(){
                HashMap的<字符串,字符串> AeyeTrack =新的HashMap<字符串,字符串>();
                字符串selectQuery =SELECT * FROM+ TABLE_TRACK;                SQLiteDatabase分贝= this.getReadableDatabase();
                光标光标= db.rawQuery(selectQuery,NULL);
                //移到第一行
                cursor.moveToFirst();
                如果(cursor.getCount()大于0){
                    AeyeTrack.put(idtrack,cursor.getString(1));
                    AeyeTrack.put(docketno,cursor.getString(2));
                    AeyeTrack.put(UID,cursor.getString(3));
                    AeyeTrack.put(dealername,cursor.getString(4));
                    AeyeTrack.put(客户名称,cursor.getString(5));
                    AeyeTrack.put(PCS,cursor.getString(6));
                    AeyeTrack.put(deliverstatus,cursor.getString(7));
                    AeyeTrack.put(备注,cursor.getString(8));
                    AeyeTrack.put(created_at_track,cursor.getString(9));
                }                cursor.close();
                db.close();
                //回报用户
                返回AeyeTrack;
            }            / **
             *充分利用数据库​​中的用户数据
             * * /
            公众的HashMap<字符串,字符串> getUserDetails(){
                HashMap的<字符串,字符串>用户=新的HashMap<字符串,字符串>();
                字符串selectQuery =SELECT * FROM+ TABLE_LOGIN;                SQLiteDatabase分贝= this.getReadableDatabase();
                光标光标= db.rawQuery(selectQuery,NULL);
                //移到第一行
                cursor.moveToFirst();
                如果(cursor.getCount()大于0){
                    user.put(姓名,cursor.getString(1));
                    user.put(电子邮件,cursor.getString(2));
                    user.put(UID,cursor.getString(3));
                    user.put(created_at,cursor.getString(4));
                }
                cursor.close();
                db.close();
                //回报用户
                返回用户;
            }            / **
             *如果获取行是否有表用户登录状态返回true
             * * /
            公众诠释getRowCount(){
                字符串countQuery =SELECT * FROM+ TABLE_LOGIN;                SQLiteDatabase分贝= this.getReadableDatabase();
                光标光标= db.rawQuery(countQuery,NULL);
                INT rowCount等= cursor.getCount();
                db.close();
                cursor.close();                //返回行计数
                返回rowCount等;
            }            / **
             *重新创建数据库中删除所有表并重新创建它们
             * * /
            公共无效resetTables(){
                SQLiteDatabase分贝= this.getWritableDatabase();
                //删除所有行
                db.delete(TABLE_LOGIN,NULL,NULL);
                db.delete(TABLE_TRACK,NULL,NULL);
                db.close();
            }        }    这是我为我的应用程序过滤的logcat    11月1日至10日:54:03.150:I / PGA(2997):新的套接字连接:m.awl.aeyetrack(PID 2997,TID 2997)
        11月1日至10日:54:17.840:D /按钮(2997):登录
        11月1日至10日:54:17.840:我/的System.out(2997):电子邮件 - > [email protected]
        11月1日至10日:54:17.840:我/的System.out(2997):密码 - > 123456
        11月1日至10日:54:17.850:我/的System.out(2997):密码< ===> 123456
        11月1日至10日:54:17.850:我/的System.out(2997):电子邮件< ===> [email protected]
        11月1日至10日:54:17.850:我/的System.out(2997):标签< ===>登录
        11月1日至10日:54:23.560:我/的System.out(2997):响应---> {\"tag\":\"login\",\"success\":1,\"error\":0,\"uid\":\"110085\",\"user\":{\"name\":\"poonam\",\"email\":\"[email protected]\",\"created_at\":\"2015-01-03 12点42分27秒,的updated_at:空}}
        11月1日至10日:54:23.560:我/的System.out(2997):从Web服务响应 - >{\"tag\":\"login\",\"success\":1,\"error\":0,\"uid\":\"110085\",\"user\":{\"name\":\"poonam\",\"email\":\"[email protected]\",\"created_at\":\"2015-01-03 12点42分27秒,的updated_at:空}}
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):错误插入的uid = 110085 [email protected]名= poonam
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):android.database.sqlite.SQLiteConstraintException:错误code 19:约束失败
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.database.sqlite.SQLiteStatement.native_executeInsert(本机方法)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.database.sqlite.SQLiteStatement.executeInsert(SQLiteStatement.java:113)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.database.sqlite.SQLiteDatabase.insertWithOnConflict(SQLiteDatabase.java:1718)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.database.sqlite.SQLiteDatabase.insert(SQLiteDatabase.java:1591)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在com.awl.aeyetrack.utils.DatabaseHandler.addUser(DatabaseHandler.java:85)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在com.awl.aeyetrack.LoginActivity $ 1.onTaskCompleted(LoginActivity.java:156)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在com.awl.aeyetrack.utils.Controller $ AsyncHtt prequest.onPostExecute(Controller.java:126)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在com.awl.aeyetrack.utils.Controller $ AsyncHtt prequest.onPostExecute(Controller.java:1)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.os.AsyncTask.finish(AsyncTask.java:602)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.os.AsyncTask.access $ 600(AsyncTask.java:156)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.os.AsyncTask $ InternalHandler.handleMessage(AsyncTask.java:615)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.os.Handler.dispatchMessage(Handler.java:99)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.os.Looper.loop(Looper.java:137)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在android.app.ActivityThread.main(ActivityThread.java:4424)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在java.lang.reflect.Method.invokeNative(本机方法)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在java.lang.reflect.Method.invoke(Method.java:511)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在com.android.internal.os.ZygoteInit $ MethodAndArgsCaller.run(ZygoteInit.java:825)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在com.android.internal.os.ZygoteInit.main(ZygoteInit.java:592)
        11月1日至10日:54:23.630:E / SQLiteDatabase(2997):在dalvik.system.NativeStart.main(本机方法)
        11月1日至10日:54:25.770:D / dalvikvm(2997):试图加载的lib /data/data/com.awl.aeyetrack/lib/libiconv.so 0xb30aa270
        11月1日至10日:54:25.770:D / dalvikvm(2997):增加了共享库/data/data/com.awl.aeyetrack/lib/libiconv.so 0xb30aa270
        11月1日至10日:54:25.770:D / dalvikvm(2997年):无JNI_OnLoad在/data/data/com.awl.aeyetrack/lib/libiconv.so 0xb30aa270发现,跳过的init
        11月1日至10日:54:25.770:D / dalvikvm(2997):试图加载的lib /data/data/com.awl.aeyetrack/lib/libzbarjni.so 0xb30aa270
        11月1日至10日:54:25.770:D / dalvikvm(2997):增加了共享库/data/data/com.awl.aeyetrack/lib/libzbarjni.so 0xb30aa270
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++不扫描/system/lib/libwebcore.so'的'init'的(错CL)
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++扫描/data/data/com.awl.aeyetrack/lib/libiconv.so为初始化
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_init)
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_init__)
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++扫描/data/data/com.awl.aeyetrack/lib/libzbarjni.so为初始化
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_init)
        11月1日至10日:54:25.770:V / dalvikvm(2997):使用dlsym找到'Java_net_sourceforge_zbar_ImageScanner_init' - FUNC = 0xab81c600
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++不扫描/system/lib/libwebcore.so为创造(错误CL)
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++扫描/data/data/com.awl.aeyetrack/lib/libiconv.so为创造
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_create)
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_create__)
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++扫描/data/data/com.awl.aeyetrack/lib/libzbarjni.so为创造
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_create)
        11月1日至10日:54:25.770:V / dalvikvm(2997):发现Java_net_sourceforge_zbar_ImageScanner_create使用dlsym - FUNC = 0xab81c7d0
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++不扫描/system/lib/libwebcore.so'为'调用setConfig(错误CL)
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++扫描/data/data/com.awl.aeyetrack/lib/libiconv.so'为'调用setConfig
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_setConfig)
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_setConfig__III)
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++扫描/data/data/com.awl.aeyetrack/lib/libzbarjni.so'为'调用setConfig
        11月1日至10日:54:25.770:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_setConfig)
        11月1日至10日:54:25.770:V / dalvikvm(2997):发现Java_net_sourceforge_zbar_ImageScanner_setConfig使用dlsym - FUNC = 0xab81c740
        11月1日至10日:54:25.940:D / dalvikvm(2997):GC_FOR_ALLOC释放1334K,35%免费6689K / 10243K,暂停10毫秒
        11月1日至10日:54:25.950:D / dalvikvm(2997):试图加载的lib /data/data/com.awl.aeyetrack/lib/libzbarjni.so 0xb30aa270
        11月1日至10日:54:25.950:D / dalvikvm(2997):共享库/data/data/com.awl.aeyetrack/lib/libzbarjni.so已经加载相同的CL 0xb30aa270        11月1日至10日:54:25.950:V / dalvikvm(2997):+++不扫描/system/lib/libwebcore.so'的'和setFormat(错误CL)
        11月1日至10日:54:25.950:V / dalvikvm(2997):+++扫描/data/data/com.awl.aeyetrack/lib/libiconv.so'的'和setFormat
        11月1日至10日:54:25.950:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Image_setFormat)
        11月1日至10日:54:25.950:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Image_setFormat__Ljava_lang_String_2)
        11月1日至10日:54:25.950:V / dalvikvm(2997):+++扫描/data/data/com.awl.aeyetrack/lib/libzbarjni.so'的'和setFormat
        11月1日至10日:54:25.950:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Image_setFormat)
dlsy
        11月1日至10日:54:25.950:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_ImageScanner_scanImage)
        11月1日至10日:54:25.950:V / dalvikvm(2997):发现Java_net_sourceforge_zbar_ImageScanner_scanImage使用dlsym - FUNC = 0xab81dce0
        11月1日至10日:54:26.120:D / dalvikvm(2997):GC_FOR_ALLOC释放95K,免费7957K / 10755K 27%,暂停0毫秒
        11月1日至10日:55:03.550:D / dalvikvm(2997):试图加载的lib /data/data/com.awl.aeyetrack/lib/libzbarjni.so 0xb30aa270
        11月1日至10日:55:03.550:D / dalvikvm(2997):共享库/data/data/com.awl.aeyetrack/lib/libzbarjni.so已经加载相同的CL 0xb30aa270
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++检索/data/data/com.awl.aeyetrack/lib/libzbarjni.so的OnLoad状态
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++较早的OnLoad(/data/data/com.awl.aeyetrack/lib/libzbarjni.so)好吗
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++不扫描/system/lib/libwebcore.so'的'init'的(错CL)
      对dlsym(Java_net_sourceforge_zbar_Symbol_next)
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Symbol_next__)
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++扫描/data/data/com.awl.aeyetrack/lib/libzbarjni.so'为'下一个'
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Symbol_next)
        11月1日至10日:55:03.550:V / dalvikvm(2997):发现Java_net_sourceforge_zbar_Symbol_next使用dlsym - FUNC = 0xab81d100
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++不扫描/system/lib/libwebcore.so代表的getData(错误CL)
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++扫描'/data/data/com.awl.aeyetrack/lib/libiconv.so'为'的getData'
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Symbol_getData)
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Symbol_getData__)
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++扫描'/data/data/com.awl.aeyetrack/lib/libzbarjni.so'为'的getData'
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Symbol_getData)
        11月1日至10日:55:03.550:V / dalvikvm(2997):发现Java_net_sourceforge_zbar_Symbol_getData使用dlsym - FUNC = 0xab81d340
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++不扫描/system/lib/libwebcore.so'为'的getType(错误CL)
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++扫描'/data/data/com.awl.aeyetrack/lib/libiconv.so'为'的getType'
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Symbol_getType)
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Symbol_getType__J)
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++扫描'/data/data/com.awl.aeyetrack/lib/libzbarjni.so'为'的getType'
        11月1日至10日:55:03.550:V / dalvikvm(2997):+++调用的dlsym(Java_net_sourceforge_zbar_Symbol_getType)
        11月1日至10日:55:03.550:V / dalvikvm(2997):发现Java_net_sourceforge_zbar_Symbol_getType使用dlsym - FUNC = 0xab81d4e0
        11月1日至10日:55:03.630:我/的System.out(2997):扫描结果---> 122100138237
        11月1日至10日:55:03.690:I / dalvikvm(2997):找不到方法android.view.ViewGroup.onNestedScrollAccepted,从方法引用android.support.v7.internal.widget.ActionBarOverlayLayout.onNestedScrollAccepted
        11月1日至10日:55:03.690:W / dalvikvm(2997):VFY:无法解析虚方法11401:Landroid /浏览/ ViewGroup中; .onNestedScrollAccepted(Landroid /视图/视图; Landroid /视图/视图;我)V
        11月1日至10日:55:03.690:D / dalvikvm(2997):VFY:在更换运code 0x6f为0x0000
        11月1日至10日:55:03.690:I / dalvikvm(2997):找不到方法android.view.ViewGroup.onStopNestedScroll,从方法引用android.support.v7.internal.widget.ActionBarOverlayLayout.onStopNestedScroll
        11月1日至10日:55:03.690:W / dalvikvm(2997):VFY:无法解析虚方法11407:Landroid /浏览/ ViewGroup中; .onStopNestedScroll(Landroid /视图/视图;)V
        11月1日至10日:55:03.690:D / dalvikvm(2997):VFY:在更换运code 0x6f为0x0000
        11月1日至10日:55:03.690:I / dalvikvm(2997):找不到方法android.view.ViewGroup.onWindowSystemUiVisibilityChanged,从方法引用android.support.v7.internal.widget.ActionBarOverlayLayout.onWindowSystemUiVisibilityChanged
        11月1日至10日:55:03.690:W / dalvikvm(2997):VFY:无法解析虚方法11409:Landroid /浏览/ ViewGroup中; .onWindowSystemUiVisibilityChanged(我)V
        11月1日至10日:55:03.690:D / dalvikvm(2997):VFY:在更换运code 0x6f×0008
        11月1日至10日:55:03.690:I / dalvikvm(2997):找不到方法android.support.v7.internal.widget.ActionBarOverlayLayout.stopNestedScroll,从方法引用android.support.v7.internal.widget.ActionBarOverlayLayout.setHideOnContentScrollEnabled
        11月1日至10日:55:03.690:W / dalvikvm(2997):VFY:无法解析虚方法9088:Landroid /支持/ V7 /内部/空间/ ActionBarOverlayLayout; .stopNestedScroll()V
        11月1日至10日:55:03.690:D / dalvikvm(2997):VFY:在0x000e更换运code 0x6e
        11月1日至10日:55:03.700:I / dalvikvm(2997):找不到方法android.view.ViewGroup.onRtlPropertiesChanged,从方法引用android.support.v7.widget.Toolbar.onRtlPropertiesChanged
        11月1日至10日:55:03.700:W / dalvikvm(2997):VFY:无法解析虚方法11404:香格里拉
        11月1日至10日:55:03.740:我/的System.out(2997):得到这个扫描结果从意向 - GT&; 122100138237
        11月1日至10日:55:03.740:I / SqliteDatabaseCpp(2997):sqlite的返回:错误code = 1,味精=没有这样的表:轨道,DB = /数据/数据​​/ com.awl.aeyetrack /数据库/ android_api
        11月1日至10日:55:03.740:D / AndroidRuntime(2997):关闭VM
        11月1日至10日:55:03.740:W / dalvikvm(2997):主题ID = 1:螺纹未捕获的异常退出(组= 0xb2c6b180)
        11月1日至10日:55:03.740:D / AndroidRuntime(2997):从PROCNAME CMDLINE:com.awl.aeyetrack
        11月1日至10日:55:03.740:E / AndroidRuntime(2997):在writeCrashedAppName,PKGNAME:com.awl.aeyetrack
        11月1日至10日:55:03.740:D / AndroidRuntime(2997):与内容成功写入文件:com.awl.aeyetrack的StringBuffer:; com.awl.aeyetrack
        11月1日至10日:55:03.750:I /流程(2997):发送信号。 PID:2997 SIG:9
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):致命异常:主要
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):了java.lang.RuntimeException:无法启动活动ComponentInfo {com.awl.aeyetrack / com.awl.aeyetrack.DashboardActivity}:android.database.sqlite.SQLiteException :没有这样的表:轨道:,编译时:SELECT * FROM轨道
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1956)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1981)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在android.app.ActivityThread.access $ 600(ActivityThread.java:123)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在android.app.ActivityThread $ H.handleMessage(ActivityThread.java:1147)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在android.os.Handler.dispatchMessage(Handler.java:99)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在android.os.Looper.loop(Looper.java:137)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在android.app.ActivityThread.main(ActivityThread.java:4424)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在java.lang.reflect.Method.invokeNative(本机方法)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在java.lang.reflect.Method.invoke(Method.java:511)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在com.android.internal.os.ZygoteInit $ MethodAndArgsCaller.run(ZygoteInit.java:825)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在com.android.internal.os.ZygoteInit.main(ZygoteInit.java:592)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):在dalvik.system.NativeStart.main(本机方法)
        11月1日至10日:55:03.750:E / AndroidRuntime(2997):android.database.sqlite.SQLiteException:没有这样的表:轨道:所致,在编译时:SELECT * FROM轨道


解决方案

我看到你在你的CREATE_TABLE_TRACK两个主键所以才删除那些要解决的问题之一。像这样的:

  //只是删除ypur主键之一
字符串CREATE_TABLE_TRACK =CREATE TABLE+ TABLE_TRACK +(
                    + KEY_UIDTRACK +INTEGER PRIMARY KEY,+ KEY_DOCKETNO
                    +INTEGER,+ KEY_DEALERNAME +TEXT
                    + KEY_CUSTOMERNAME +TEXT+ KEY_PCS
                    +INTEGER,+ KEY_DELIVERY_STATUS +TEXT
                    + KEY_REMARKS +TEXT+ KEY_CREATED_AT_TRACK +TEXT
                    +);

作为@Mike中号说,你在你的code有一些语法错误。我固定的他们。

I am getting this error and doing first time so any suggestions, why it is coming and how to resolve it.From this link i didnt get any help android.database.sqlite.SQLiteException near DATABASE_TABLE_NAME syntax error(code:1) while compiling organizationSetup

Database handler

        public class DatabaseHandler extends SQLiteOpenHelper {

            // All Static variables
            // Database Version
            private static final int DATABASE_VERSION = 1;

            // Database Name
            private static final String DATABASE_NAME = "android_api";

            // Login table name
            private static final String TABLE_LOGIN = "login";
            private static final String TABLE_TRACK = "track";
            // Login Table Columns names
            private static final String KEY_ID = "id";
            private static final String KEY_NAME = "name";
            private static final String KEY_EMAIL = "email";
            private static final String KEY_UID = "uid";
            private static final String KEY_CREATED_AT = "created_at";
            // Track Table Columns names
            private static final String KEY_UIDTRACK = "idtrack";
            private static final String KEY_DOCKETNO = "docketno";
            private static final String KEY_DEALERNAME = "dealername";
            private static final String KEY_CUSTOMERNAME = "customername";
            private static final String KEY_PCS = "pcs";
            private static final String KEY_DELIVERY_STATUS = "deliverstatus";
            private static final String KEY_REMARKS = "remarks";
            private static final String KEY_CREATED_AT_TRACK = "created_at_track";

            public DatabaseHandler(Context context) {
                super(context, DATABASE_NAME, null, DATABASE_VERSION);
            }

            // Creating Tables
            @Override
            public void onCreate(SQLiteDatabase db) {
                String CREATE_LOGIN_TABLE = "CREATE TABLE " + TABLE_LOGIN + "("
                        + KEY_ID + " INTEGER PRIMARY KEY," + KEY_NAME + " TEXT,"
                        + KEY_EMAIL + " TEXT UNIQUE," + KEY_UID + " TEXT,"
                        + KEY_CREATED_AT + " TEXT" + ")";


                String CREATE_TABLE_TRACK = "CREATE TABLE " + TABLE_TRACK + "("
                        + KEY_UIDTRACK + " INTEGER PRIMARY KEY," + KEY_DOCKETNO
                        + "INTEGER PRIMARY KEY," + KEY_DEALERNAME + " TEXT,"
                        + KEY_CUSTOMERNAME + " TEXT ," + KEY_PCS
                        + "INTEGER PRIMARY KEY," + KEY_DELIVERY_STATUS + " TEXT ,"
                        + KEY_REMARKS + " TEXT ," + KEY_CREATED_AT_TRACK + " TEXT"
                        + ")";
                 db.execSQL(CREATE_LOGIN_TABLE);
                 db.execSQL(CREATE_TABLE_TRACK);
            }

            // Upgrading database
            @Override
            public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
                // Drop older table if existed
                db.execSQL("DROP TABLE IF EXISTS " + TABLE_LOGIN);
                db.execSQL("DROP TABLE IF EXISTS " + TABLE_TRACK);
                // Create tables again
                onCreate(db);
            }

            /**
             * Storing user details in database
             * */
            public void addUser(String name, String email, String uid, String created_at) {
                SQLiteDatabase db = this.getWritableDatabase();

                ContentValues values = new ContentValues();
                values.put(KEY_NAME, name); // Name
                values.put(KEY_EMAIL, email); // Email
                values.put(KEY_UID, uid); // Email

                // Inserting Row
                db.insert(TABLE_LOGIN, null, values);
                db.close(); // Closing database connection
            }

            /**
             * Storing AeyeTrack details in database
             * */
            public void addAeyeTrack(Integer idtrack, Integer docketno,
                    String dealername, String customername, Integer pcs,
                    String deliverstatus, String remarks, String created_at_track) {
                SQLiteDatabase db = this.getWritableDatabase();

                ContentValues values = new ContentValues();

                values.put(KEY_UIDTRACK, idtrack); // idtrack
                values.put(KEY_DOCKETNO, docketno); // docketno
                values.put(KEY_DEALERNAME, dealername); // dealername
                values.put(KEY_CUSTOMERNAME, customername); // customername
                values.put(KEY_PCS, pcs); // pcs
                values.put(KEY_DELIVERY_STATUS, deliverstatus); // deliverstatus
                values.put(KEY_REMARKS, remarks); // remarks
                values.put(KEY_CREATED_AT_TRACK, created_at_track); // created_at_track

                // Inserting Row
                db.insert(TABLE_TRACK, null, values);
                db.close(); // Closing database connection
            }

            /**
             * Getting update AeyeTrack data from database
             * */
            public boolean updateAeyeTrack(Integer idtrack, Integer docketno,
                    String dealername, String customername, Integer pcs,
                    String deliverstatus, String remarks, String created_at_track) {
                SQLiteDatabase db = this.getWritableDatabase();
                ContentValues contentValues = new ContentValues();
                contentValues.put(KEY_UIDTRACK, idtrack); // idtrack
                contentValues.put(KEY_DOCKETNO, docketno); // docketno
                contentValues.put(KEY_DEALERNAME, dealername); // dealername
                contentValues.put(KEY_CUSTOMERNAME, customername); // customername
                contentValues.put(KEY_PCS, pcs); // pcs
                contentValues.put(KEY_DELIVERY_STATUS, deliverstatus); // deliverstatus
                contentValues.put(KEY_REMARKS, remarks); // remarks
                contentValues.put(KEY_CREATED_AT_TRACK, created_at_track); // created_at_track

                db.update("track", contentValues, "idtrack = ? ",
                        new String[] { Integer.toString(idtrack) });
                return true;
            }



            /**
             * Getting AeyeTrack data from database
             * */
            public HashMap<String, String> getAeyeTrackDetails() {
                HashMap<String, String> AeyeTrack = new HashMap<String, String>();
                String selectQuery = "SELECT  * FROM " + TABLE_TRACK;

                SQLiteDatabase db = this.getReadableDatabase();
                Cursor cursor = db.rawQuery(selectQuery, null);
                // Move to first row
                cursor.moveToFirst();
                if (cursor.getCount() > 0) {
                    AeyeTrack.put("idtrack", cursor.getString(1));
                    AeyeTrack.put("docketno", cursor.getString(2));
                    AeyeTrack.put("uid", cursor.getString(3));
                    AeyeTrack.put("dealername", cursor.getString(4));
                    AeyeTrack.put("customername", cursor.getString(5));
                    AeyeTrack.put("pcs", cursor.getString(6));
                    AeyeTrack.put("deliverstatus", cursor.getString(7));
                    AeyeTrack.put("remarks", cursor.getString(8));
                    AeyeTrack.put("created_at_track", cursor.getString(9));
                }

                cursor.close();
                db.close();
                // return user
                return AeyeTrack;
            }

            /**
             * Getting user data from database
             * */
            public HashMap<String, String> getUserDetails() {
                HashMap<String, String> user = new HashMap<String, String>();
                String selectQuery = "SELECT  * FROM " + TABLE_LOGIN;

                SQLiteDatabase db = this.getReadableDatabase();
                Cursor cursor = db.rawQuery(selectQuery, null);
                // Move to first row
                cursor.moveToFirst();
                if (cursor.getCount() > 0) {
                    user.put("name", cursor.getString(1));
                    user.put("email", cursor.getString(2));
                    user.put("uid", cursor.getString(3));
                    user.put("created_at", cursor.getString(4));
                }
                cursor.close();
                db.close();
                // return user
                return user;
            }

            /**
             * Getting user login status return true if rows are there in table
             * */
            public int getRowCount() {
                String countQuery = "SELECT  * FROM " + TABLE_LOGIN;

                SQLiteDatabase db = this.getReadableDatabase();
                Cursor cursor = db.rawQuery(countQuery, null);
                int rowCount = cursor.getCount();
                db.close();
                cursor.close();

                // return row count
                return rowCount;
            }

            /**
             * Re create database Delete all tables and create them again
             * */
            public void resetTables() {
                SQLiteDatabase db = this.getWritableDatabase();
                // Delete All Rows
                db.delete(TABLE_LOGIN, null, null);
                db.delete(TABLE_TRACK, null, null);
                db.close();
            }

        }

    This is my filtered logcat for my app

    01-10 11:54:03.150: I/PGA(2997): New SOCKET connection: m.awl.aeyetrack (pid 2997, tid 2997)
        01-10 11:54:17.840: D/Button(2997): Login
        01-10 11:54:17.840: I/System.out(2997): Email -- >[email protected]
        01-10 11:54:17.840: I/System.out(2997): Password-->123456
        01-10 11:54:17.850: I/System.out(2997): password  < === >  123456
        01-10 11:54:17.850: I/System.out(2997): email  < === >  [email protected]
        01-10 11:54:17.850: I/System.out(2997): tag  < === >  login
        01-10 11:54:23.560: I/System.out(2997): Response ---> {"tag":"login","success":1,"error":0,"uid":"110085","user":{"name":"poonam","email":"[email protected]","created_at":"2015-01-03 12:42:27","updated_at":null}}
        01-10 11:54:23.560: I/System.out(2997): Response from Web Service -- >{"tag":"login","success":1,"error":0,"uid":"110085","user":{"name":"poonam","email":"[email protected]","created_at":"2015-01-03 12:42:27","updated_at":null}}
        01-10 11:54:23.630: E/SQLiteDatabase(2997): Error inserting uid=110085 [email protected] name=poonam
        01-10 11:54:23.630: E/SQLiteDatabase(2997): android.database.sqlite.SQLiteConstraintException: error code 19: constraint failed
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.database.sqlite.SQLiteStatement.native_executeInsert(Native Method)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.database.sqlite.SQLiteStatement.executeInsert(SQLiteStatement.java:113)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.database.sqlite.SQLiteDatabase.insertWithOnConflict(SQLiteDatabase.java:1718)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.database.sqlite.SQLiteDatabase.insert(SQLiteDatabase.java:1591)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at com.awl.aeyetrack.utils.DatabaseHandler.addUser(DatabaseHandler.java:85)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at com.awl.aeyetrack.LoginActivity$1.onTaskCompleted(LoginActivity.java:156)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at com.awl.aeyetrack.utils.Controller$AsyncHttpRequest.onPostExecute(Controller.java:126)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at com.awl.aeyetrack.utils.Controller$AsyncHttpRequest.onPostExecute(Controller.java:1)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.os.AsyncTask.finish(AsyncTask.java:602)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.os.AsyncTask.access$600(AsyncTask.java:156)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.os.AsyncTask$InternalHandler.handleMessage(AsyncTask.java:615)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.os.Handler.dispatchMessage(Handler.java:99)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.os.Looper.loop(Looper.java:137)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at android.app.ActivityThread.main(ActivityThread.java:4424)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at java.lang.reflect.Method.invokeNative(Native Method)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at java.lang.reflect.Method.invoke(Method.java:511)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:592)
        01-10 11:54:23.630: E/SQLiteDatabase(2997):     at dalvik.system.NativeStart.main(Native Method)
        01-10 11:54:25.770: D/dalvikvm(2997): Trying to load lib /data/data/com.awl.aeyetrack/lib/libiconv.so 0xb30aa270
        01-10 11:54:25.770: D/dalvikvm(2997): Added shared lib /data/data/com.awl.aeyetrack/lib/libiconv.so 0xb30aa270
        01-10 11:54:25.770: D/dalvikvm(2997): No JNI_OnLoad found in /data/data/com.awl.aeyetrack/lib/libiconv.so 0xb30aa270, skipping init
        01-10 11:54:25.770: D/dalvikvm(2997): Trying to load lib /data/data/com.awl.aeyetrack/lib/libzbarjni.so 0xb30aa270
        01-10 11:54:25.770: D/dalvikvm(2997): Added shared lib /data/data/com.awl.aeyetrack/lib/libzbarjni.so 0xb30aa270
        01-10 11:54:25.770: V/dalvikvm(2997): +++ not scanning '/system/lib/libwebcore.so' for 'init' (wrong CL)
        01-10 11:54:25.770: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libiconv.so' for 'init'
        01-10 11:54:25.770: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_init)
        01-10 11:54:25.770: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_init__)
        01-10 11:54:25.770: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libzbarjni.so' for 'init'
        01-10 11:54:25.770: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_init)
        01-10 11:54:25.770: V/dalvikvm(2997): Found 'Java_net_sourceforge_zbar_ImageScanner_init' with dlsym - func=0xab81c600
        01-10 11:54:25.770: V/dalvikvm(2997): +++ not scanning '/system/lib/libwebcore.so' for 'create' (wrong CL)
        01-10 11:54:25.770: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libiconv.so' for 'create'
        01-10 11:54:25.770: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_create)
        01-10 11:54:25.770: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_create__)
        01-10 11:54:25.770: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libzbarjni.so' for 'create'
        01-10 11:54:25.770: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_create)
        01-10 11:54:25.770: V/dalvikvm(2997): Found 'Java_net_sourceforge_zbar_ImageScanner_create' with dlsym - func=0xab81c7d0
        01-10 11:54:25.770: V/dalvikvm(2997): +++ not scanning '/system/lib/libwebcore.so' for 'setConfig' (wrong CL)
        01-10 11:54:25.770: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libiconv.so' for 'setConfig'
        01-10 11:54:25.770: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_setConfig)
        01-10 11:54:25.770: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_setConfig__III)
        01-10 11:54:25.770: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libzbarjni.so' for 'setConfig'
        01-10 11:54:25.770: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_setConfig)
        01-10 11:54:25.770: V/dalvikvm(2997): Found 'Java_net_sourceforge_zbar_ImageScanner_setConfig' with dlsym - func=0xab81c740
        01-10 11:54:25.940: D/dalvikvm(2997): GC_FOR_ALLOC freed 1334K, 35% free 6689K/10243K, paused 10ms
        01-10 11:54:25.950: D/dalvikvm(2997): Trying to load lib /data/data/com.awl.aeyetrack/lib/libzbarjni.so 0xb30aa270
        01-10 11:54:25.950: D/dalvikvm(2997): Shared lib '/data/data/com.awl.aeyetrack/lib/libzbarjni.so' already loaded in same CL 0xb30aa270

        01-10 11:54:25.950: V/dalvikvm(2997): +++ not scanning '/system/lib/libwebcore.so' for 'setFormat' (wrong CL)
        01-10 11:54:25.950: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libiconv.so' for 'setFormat'
        01-10 11:54:25.950: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Image_setFormat)
        01-10 11:54:25.950: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Image_setFormat__Ljava_lang_String_2)
        01-10 11:54:25.950: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libzbarjni.so' for 'setFormat'
        01-10 11:54:25.950: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Image_setFormat)
dlsy
        01-10 11:54:25.950: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_ImageScanner_scanImage)
        01-10 11:54:25.950: V/dalvikvm(2997): Found 'Java_net_sourceforge_zbar_ImageScanner_scanImage' with dlsym - func=0xab81dce0
        01-10 11:54:26.120: D/dalvikvm(2997): GC_FOR_ALLOC freed 95K, 27% free 7957K/10755K, paused 0ms
        01-10 11:55:03.550: D/dalvikvm(2997): Trying to load lib /data/data/com.awl.aeyetrack/lib/libzbarjni.so 0xb30aa270
        01-10 11:55:03.550: D/dalvikvm(2997): Shared lib '/data/data/com.awl.aeyetrack/lib/libzbarjni.so' already loaded in same CL 0xb30aa270
        01-10 11:55:03.550: V/dalvikvm(2997): +++ retrieving /data/data/com.awl.aeyetrack/lib/libzbarjni.so OnLoad status
        01-10 11:55:03.550: V/dalvikvm(2997): +++ earlier OnLoad(/data/data/com.awl.aeyetrack/lib/libzbarjni.so) okay
        01-10 11:55:03.550: V/dalvikvm(2997): +++ not scanning '/system/lib/libwebcore.so' for 'init' (wrong CL)
      dlsym(Java_net_sourceforge_zbar_Symbol_next)
        01-10 11:55:03.550: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Symbol_next__)
        01-10 11:55:03.550: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libzbarjni.so' for 'next'
        01-10 11:55:03.550: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Symbol_next)
        01-10 11:55:03.550: V/dalvikvm(2997): Found 'Java_net_sourceforge_zbar_Symbol_next' with dlsym - func=0xab81d100
        01-10 11:55:03.550: V/dalvikvm(2997): +++ not scanning '/system/lib/libwebcore.so' for 'getData' (wrong CL)
        01-10 11:55:03.550: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libiconv.so' for 'getData'
        01-10 11:55:03.550: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Symbol_getData)
        01-10 11:55:03.550: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Symbol_getData__)
        01-10 11:55:03.550: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libzbarjni.so' for 'getData'
        01-10 11:55:03.550: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Symbol_getData)
        01-10 11:55:03.550: V/dalvikvm(2997): Found 'Java_net_sourceforge_zbar_Symbol_getData' with dlsym - func=0xab81d340
        01-10 11:55:03.550: V/dalvikvm(2997): +++ not scanning '/system/lib/libwebcore.so' for 'getType' (wrong CL)
        01-10 11:55:03.550: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libiconv.so' for 'getType'
        01-10 11:55:03.550: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Symbol_getType)
        01-10 11:55:03.550: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Symbol_getType__J)
        01-10 11:55:03.550: V/dalvikvm(2997): +++ scanning '/data/data/com.awl.aeyetrack/lib/libzbarjni.so' for 'getType'
        01-10 11:55:03.550: V/dalvikvm(2997): +++ calling dlsym(Java_net_sourceforge_zbar_Symbol_getType)
        01-10 11:55:03.550: V/dalvikvm(2997): Found 'Java_net_sourceforge_zbar_Symbol_getType' with dlsym - func=0xab81d4e0
        01-10 11:55:03.630: I/System.out(2997): Scanned Result--->122100138237
        01-10 11:55:03.690: I/dalvikvm(2997): Could not find method android.view.ViewGroup.onNestedScrollAccepted, referenced from method android.support.v7.internal.widget.ActionBarOverlayLayout.onNestedScrollAccepted
        01-10 11:55:03.690: W/dalvikvm(2997): VFY: unable to resolve virtual method 11401: Landroid/view/ViewGroup;.onNestedScrollAccepted (Landroid/view/View;Landroid/view/View;I)V
        01-10 11:55:03.690: D/dalvikvm(2997): VFY: replacing opcode 0x6f at 0x0000
        01-10 11:55:03.690: I/dalvikvm(2997): Could not find method android.view.ViewGroup.onStopNestedScroll, referenced from method android.support.v7.internal.widget.ActionBarOverlayLayout.onStopNestedScroll
        01-10 11:55:03.690: W/dalvikvm(2997): VFY: unable to resolve virtual method 11407: Landroid/view/ViewGroup;.onStopNestedScroll (Landroid/view/View;)V
        01-10 11:55:03.690: D/dalvikvm(2997): VFY: replacing opcode 0x6f at 0x0000
        01-10 11:55:03.690: I/dalvikvm(2997): Could not find method android.view.ViewGroup.onWindowSystemUiVisibilityChanged, referenced from method android.support.v7.internal.widget.ActionBarOverlayLayout.onWindowSystemUiVisibilityChanged
        01-10 11:55:03.690: W/dalvikvm(2997): VFY: unable to resolve virtual method 11409: Landroid/view/ViewGroup;.onWindowSystemUiVisibilityChanged (I)V
        01-10 11:55:03.690: D/dalvikvm(2997): VFY: replacing opcode 0x6f at 0x0008
        01-10 11:55:03.690: I/dalvikvm(2997): Could not find method android.support.v7.internal.widget.ActionBarOverlayLayout.stopNestedScroll, referenced from method android.support.v7.internal.widget.ActionBarOverlayLayout.setHideOnContentScrollEnabled
        01-10 11:55:03.690: W/dalvikvm(2997): VFY: unable to resolve virtual method 9088: Landroid/support/v7/internal/widget/ActionBarOverlayLayout;.stopNestedScroll ()V
        01-10 11:55:03.690: D/dalvikvm(2997): VFY: replacing opcode 0x6e at 0x000e
        01-10 11:55:03.700: I/dalvikvm(2997): Could not find method android.view.ViewGroup.onRtlPropertiesChanged, referenced from method android.support.v7.widget.Toolbar.onRtlPropertiesChanged
        01-10 11:55:03.700: W/dalvikvm(2997): VFY: unable to resolve virtual method 11404: La
        01-10 11:55:03.740: I/System.out(2997): Got this Scanned Result From Intent-->122100138237
        01-10 11:55:03.740: I/SqliteDatabaseCpp(2997): sqlite returned: error code = 1, msg = no such table: track, db=/data/data/com.awl.aeyetrack/databases/android_api
        01-10 11:55:03.740: D/AndroidRuntime(2997): Shutting down VM
        01-10 11:55:03.740: W/dalvikvm(2997): threadid=1: thread exiting with uncaught exception (group=0xb2c6b180)
        01-10 11:55:03.740: D/AndroidRuntime(2997): procName from cmdline: com.awl.aeyetrack
        01-10 11:55:03.740: E/AndroidRuntime(2997): in writeCrashedAppName, pkgName :com.awl.aeyetrack
        01-10 11:55:03.740: D/AndroidRuntime(2997): file written successfully with content: com.awl.aeyetrack StringBuffer : ;com.awl.aeyetrack
        01-10 11:55:03.750: I/Process(2997): Sending signal. PID: 2997 SIG: 9
        01-10 11:55:03.750: E/AndroidRuntime(2997): FATAL EXCEPTION: main
        01-10 11:55:03.750: E/AndroidRuntime(2997): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.awl.aeyetrack/com.awl.aeyetrack.DashboardActivity}: android.database.sqlite.SQLiteException: no such table: track: , while compiling: SELECT  * FROM track
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1956)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1981)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at android.app.ActivityThread.access$600(ActivityThread.java:123)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1147)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at android.os.Handler.dispatchMessage(Handler.java:99)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at android.os.Looper.loop(Looper.java:137)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at android.app.ActivityThread.main(ActivityThread.java:4424)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at java.lang.reflect.Method.invokeNative(Native Method)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at java.lang.reflect.Method.invoke(Method.java:511)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:592)
        01-10 11:55:03.750: E/AndroidRuntime(2997):     at dalvik.system.NativeStart.main(Native Method)
        01-10 11:55:03.750: E/AndroidRuntime(2997): Caused by: android.database.sqlite.SQLiteException: no such table: track: , while compiling: SELECT  * FROM track
解决方案

I see in you have two primary keys in your CREATE_TABLE_TRACK so just remove one of those to solve the problem. like this :

//just removed one of ypur primary keys
String CREATE_TABLE_TRACK = "CREATE TABLE " + TABLE_TRACK + "("
                    + KEY_UIDTRACK + " INTEGER PRIMARY KEY," + KEY_DOCKETNO
                    + " INTEGER ," + KEY_DEALERNAME + " TEXT,"
                    + KEY_CUSTOMERNAME + " TEXT ," + KEY_PCS
                    + " INTEGER ," + KEY_DELIVERY_STATUS + " TEXT ,"
                    + KEY_REMARKS + " TEXT ," + KEY_CREATED_AT_TRACK + " TEXT"
                    + ")";

as @Mike M said you have some syntax errors in your code. I fixed them too.

这篇关于无法启动活动,android.database.sqlite.SQLiteException:没有这样的表,在编译时:SELECT * FROM表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-02 19:05