求助!
本人是一名在校学生,利用课余时间学习安卓开发,前几日遇到了这个问题,在网上搜的答案很多,可没用,有的我还看不懂是怎么回事,请原谅我这个初学者吧……言归正传,问题是CREATE TABLE android_metadata failed……log.txt内容如下:(找不到上传文件的地方啊)
11-28 15:47:19.313: E/Database(8658): CREATE TABLE android_metadata failed
11-28 15:47:19.313: E/Database(8658): native_setLocale: errno = 13, error message = Permission denied
11-28 15:47:19.353: E/Database(8658): Failed to setLocale() when constructing, closing the database
11-28 15:47:19.353: E/Database(8658): android.database.sqlite.SQLiteException: unable to open database file
11-28 15:47:19.353: E/Database(8658): at android.database.sqlite.SQLiteDatabase.native_setLocale(Native Method)
11-28 15:47:19.353: E/Database(8658): at android.database.sqlite.SQLiteDatabase.setLocale(SQLiteDatabase.java:2101)
11-28 15:47:19.353: E/Database(8658): at android.database.sqlite.SQLiteDatabase.<init>(SQLiteDatabase.java:1969)
11-28 15:47:19.353: E/Database(8658): at android.database.sqlite.SQLiteDatabase.openDatabase(SQLiteDatabase.java:902)
11-28 15:47:19.353: E/Database(8658): at android.database.sqlite.SQLiteDatabase.openOrCreateDatabase(SQLiteDatabase.java:936)
11-28 15:47:19.353: E/Database(8658): at com.niu.tcdbeta1.Main.openDatabase(Main.java:71)
11-28 15:47:19.353: E/Database(8658): at com.niu.tcdbeta1.Main.onCreate(Main.java:38)
11-28 15:47:19.353: E/Database(8658): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1072)
11-28 15:47:19.353: E/Database(8658): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1813)
11-28 15:47:19.353: E/Database(8658): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1870)
11-28 15:47:19.353: E/Database(8658): at android.app.ActivityThread.access$1500(ActivityThread.java:132)
11-28 15:47:19.353: E/Database(8658): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1051)
11-28 15:47:19.353: E/Database(8658): at android.os.Handler.dispatchMessage(Handler.java:99)
11-28 15:47:19.353: E/Database(8658): at android.os.Looper.loop(Looper.java:150)
11-28 15:47:19.353: E/Database(8658): at android.app.ActivityThread.main(ActivityThread.java:4319)
11-28 15:47:19.353: E/Database(8658): at java.lang.reflect.Method.invokeNative(Native Method)
11-28 15:47:19.353: E/Database(8658): at java.lang.reflect.Method.invoke(Method.java:507)
11-28 15:47:19.353: E/Database(8658): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:849)
11-28 15:47:19.353: E/Database(8658): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:607)
11-28 15:47:19.353: E/Database(8658): at dalvik.system.NativeStart.main(Native Method)
好了,谢谢各位大神了!!
小弟在此谢过!!
网上有人说是因为线程的原因,可是我的源码里并没有涉及线程啊……所以还望各位大神不吝赐教!! android,sqlite数据库
补充:移动开发 , Android