-1

In eclipse I used a plugin to view database table structure, but in Android Studio I can't find any such plugin. Could you please suggest one?

Mureinik
  • 297,002
  • 52
  • 306
  • 350

1 Answers1

1

Since you need to do it frequently when you are working for the app involving to the database storage so configure for the following settings-

  1. set adb.exe to your current path variable.You can google it if you are facing the issue with setting the path variables.
  2. You can run the following command to access the shell of the device/emulator

    adb shell

  3. Now you can navigate to your database folder by using the cd command as cd /data/data/YOUR_PACKAGE_NAME/databses
  4. You can ensure the database is created or not, You can use the following command to open the database Sqlite3 YOUR_DATABASE_NAME
  5. For the convenience you can run the following commands also .mode column .headers on
  6. Now you can check the tables using the.tables command and use the select query to select from the tables. You can do all the sql queries now. Remember to terminate the sql quire by the semicolon.
NOTE: Ensure you have the root access to the device/emulator.
Sanjeet A
  • 5,171
  • 3
  • 23
  • 40