You can use these commands for pulling the data base from your device. Typing these commands through android studio is very easy. Please make sure you have set the path of adb globally to your system. Then open the "terminal" window from bottom to android studio and near to "Android Monitor". Now you just update the following commands with actual package name of your app and database file name. You will get your file out from the device.
adb shell "run-as package.name chmod 666 /data/data/package.name/databases/file"
adb pull /data/data/package.name/databases/file .
adb shell "run-as package.name chmod 600 /data/data/package.name/databases/file"
the command for Android 5.0+ /data/data/package.name/databases/file would be:
adb shell "run-as package.name chmod 666 /data/data/package.name/databases/file"
adb exec-out run-as package.name cat databases/file > newOutFileName
adb shell "run-as package.name chmod 600 /data/data/package.name/databases/file"