problem about sqlite database, no such table:

I open a sqlite database and use rawquery to get data.

But the log.e show the information:

  • Adding an onclicklistener to listview (android)
  • How many port number that android and ios have?
  • Android Studio Gradle BuildTools Revision
  • Upload progress bar in android?
  • How can I include a button in a Toast notification?
  • Icon not displaying in notification: white square shown instead
  • android.database.sqlite.SQLiteException: no such table: types:

    But, I really have this table.

    And i also try to use the other sql ,But also get the error message such as

    android.database.sqlite.SQLiteException: no such table: malls:

    I am sure there are this two tables.
    So why get the error message?

    Related posts:

    Number of Downloads in Google Play
    Android set GoolgeMap bounds from from database of points
    Set existing android sdk path to eclipse
    Ionic v2 Google Maps API Android Build Error: cannot access AbstractSafeParcelable options.compassEn...
    Stopping an IntentService from an activity
    Create a Marker without adding it to the map?
  • AlphaAnimation does not work
  • Distributing (and updating) an enterprise Android application that is to be used in-house only
  • Creating iOS & Android app from a simple html5 + javascript game?
  • Convert results of Sqllite Cursor to my object
  • Does Robolectric support API level?
  • Get Toolbar's navigation icon view referrence
  • 6 Solutions collect form web for “problem about sqlite database, no such table:”

    If this is on the emulator, use DDMS File Explorer or adb pull to download a copy of the database file and confirm its contents.

    And i crate a custom SQLiteOpenHelper
    to copy this file to path :
    /data/data/com.SGMalls/databases/mallMapv2.sqlite

    If you are attempting to copy the file in SQLiteOpenHelper‘s onCreate(), you are too late. I would do it before then.

    So the copy file code may be can not
    copy the complete file.

    It is more likely you would get an error about a corrupt file in that case.

    If you have multiple contents providers, you might think that your table exists while it does not. In which case the error you are getting is legitimate.

    Take a look here for details and solution:
    http://devserghini.blogspot.com/2010/11/android-sqliteopenhelper-and-multiple.html

    Some people have been able to solve the problem using the steps mentioned here. It seems to me that this problem exists on certain versions of Android 2.2. I have incorporated this change in my code, though I’m still looking for Beta testers with to see if it actually works.

    I think this error occurs when you change the table structure. To solve this, clean the data
    (Settings -> Manage application -> Clear data) before installing the new application.

    Regards.

    SQLiteDatabase.execSQL() interpretation takes a single string sql, ending with “;”. Two lines have not interpreted.

    Creating tables in a few lines sql just not executed.

    Android Babe is a Google Android Fan, All about Android Phones, Android Wear, Android Dev and Android Games Apps and so on.