teamtnt / laravel-scout-tntsearch-driver

Driver for Laravel Scout search package based on https://github.com/teamtnt/tntsearch
MIT License
1.1k stars 144 forks source link

Error: Unable to open database file #89

Closed SFPink closed 7 years ago

SFPink commented 7 years ago

Hello,

Trying to test this plugin out on my project but I am getting this error:

SQLSTATE[HY000] [14] unable to open database file

I was following this tutorial https://laravel-news.com/tntsearch-with-laravel-scout to give you an idea of what I've done so far. Have I missed something?

Regards

the94air commented 7 years ago

In witch step does it give you the error?

SFPink commented 7 years ago

Sorry I forgot that bit.

When I run the import: php artisan tntsearch:import "App\MyModel"

Additional Info:

Running Laravel: 5.4 PHP: 5.6.4 Scout: 3 Scount-tntsearch-driver: 3

the94air commented 7 years ago

Are you using SQLlite database?

SFPink commented 7 years ago

No, I'm using Postgres. Is this not supported?

stokic commented 7 years ago

Check if the file defined in your 'tntsearch' => [ 'storage' => storage_path(), ],

is readable/writable...

SFPink commented 7 years ago

Oh.. It was actually a pretty stupid mistake I had this in my config:

'tntsearch' => [ 'storage' => storage_path('/index'), ],

Index doesn't exist, It works now thanks.

Hadi-Abedzadeh commented 5 years ago

I had same problem in Windows 10, but this way was worked for me: Create search directory in storage path