PS. Eu estou querendo usar o SQLite.
PS2. eu instalei o php........... nao lembro. Devo reinstalar?
Descomento o pdo mysql e o serve roda normal, mas nao consegue fazer o migrate. Entao descomentei ambos pdo mysql e pdo sqlite pra ver noq q dava e deu:
[marilia@marilia-pc crud_rbarcos]$ php artisan serve
PHP Warning: PHP Startup: Unable to load dynamic library 'pdo_sqlite' (tried: /usr/lib/php/modules/pdo_sqlite (/usr/lib/php/modules/pdo_sqlite: cannot open shared object file: No such file or directory), /usr/lib/php/modules/pdo_sqlite.so (/usr/lib/php/modules/pdo_sqlite.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
Laravel development server started: <http://127.0.0.1:8000>
[Wed May 29 18:25:45 2019] PHP Warning: PHP Startup: Unable to load dynamic library 'pdo_sqlite' (tried: /usr/lib/php/modules/pdo_sqlite (/usr/lib/php/modules/pdo_sqlite: cannot open shared object file: No such file or directory), /usr/lib/php/modules/pdo_sqlite.so (/usr/lib/php/modules/pdo_sqlite.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
[Wed May 29 18:25:54 2019] 127.0.0.1:59238 [200]: /favicon.ico
na hora de migrar:
Illuminate\Database\QueryException : could not find driver (SQL: PRAGMA foreign_keys = ON;)
at /home/marilia/projetos/prova_rbarcos/crud_rbarcos/vendor/laravel/framework/src/Illuminate/Database/Connection.php:664
660| // If an exception occurs when attempting to run a query, we'll format the error
661| // message to include the bindings with SQL, which will make this exception a
662| // lot more helpful to the developer instead of just the database's errors.
663| catch (Exception $e) {
> 664| throw new QueryException(
665| $query, $this->prepareBindings($bindings), $e
666| );
667| }
668|
Exception trace:
1 PDOException::("could not find driver")
/home/marilia/projetos/prova_rbarcos/crud_rbarcos/vendor/laravel/framework/src/Illuminate/Database/Connectors/Connector.php:70
2 PDO::__construct("sqlite:/home/marilia/projetos/prova_rbarcos/crud_rbarcos/database/database.sqlite", [])
/home/marilia/projetos/prova_rbarcos/crud_rbarcos/vendor/laravel/framework/src/Illuminate/Database/Connectors/Connector.php:70
Please use the argument -v to see more details.
Whoops\Exception\ErrorException : PHP Startup: Unable to load dynamic library 'pdo_sqlite' (tried: /usr/lib/php/modules/pdo_sqlite (/usr/lib/php/modules/pdo_sqlite: cannot open shared object file: No such file or directory), /usr/lib/php/modules/pdo_sqlite.so (/usr/lib/php/modules/pdo_sqlite.so: cannot open shared object file: No such file or directory))
at Unknown:0
1|
"basta descomentar no php.ini a linha extension=php_mysql."
nao tem essa extensao no meu. Essas sao as extensoes PDO no meu php.ini
;extension=pdo_dblib
;extension=pdo_mysql
;extension=pdo_odbc
;extension=pdo_pgsql
;extension=pdo_sqlite
entao deixo so o pdo mysql descomentado e na hora de fazer a migraçao:
Illuminate\Database\QueryException : could not find driver (SQL: PRAGMA foreign_keys = ON;)
at /home/marilia/projetos/prova_rbarcos/crud_rbarcos/vendor/laravel/framework/src/Illuminate/Database/Connection.php:664
660| // If an exception occurs when attempting to run a query, we'll format the error
661| // message to include the bindings with SQL, which will make this exception a
662| // lot more helpful to the developer instead of just the database's errors.
663| catch (Exception $e) {
> 664| throw new QueryException(
665| $query, $this->prepareBindings($bindings), $e
666| );
667| }
668|
Exception trace:
1 PDOException::("could not find driver")
/home/marilia/projetos/prova_rbarcos/crud_rbarcos/vendor/laravel/framework/src/Illuminate/Database/Connectors/Connector.php:70
2 PDO::__construct("sqlite:/home/marilia/projetos/prova_rbarcos/crud_rbarcos/database/database.sqlite", [])
/home/marilia/projetos/prova_rbarcos/crud_rbarcos/vendor/laravel/framework/src/Illuminate/Database/Connectors/Connector.php:70
Please use the argument -v to see more details.
to mais perdida q cego em tiroteio