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


  • | 87 points

    i face to this error in laravel with working by laragon .

    please help me fox.


  • administrators
    | 102520 points

    @Henryway: Which database system are you using? (SQLite I guess)


  • | 87 points

    yes i am using data base

    how can i know that sqlite is installed in laragon?
    i use npm install sqlite in terminal . it install but didnt work


  • administrators
    | 102520 points

    There is a tutorial about using Laragon + Laravel + SQLite created by CoffeeTimeCode. You can check it here:


  • | 87 points

    thanks i understand what was my problem.

    write for others
    in .env file in laravel we should remove ::
    DB_HOST=127.0.0.1
    DB_PORT=3306
    DB_DATABASE=database
    DB_USERNAME=homestead

    just write
    DB_CONNECTION=sqlite

    best regards


Log in to reply
 

Looks like your connection to Laragon was lost, please wait while we try to reconnect.