fixed it by:
In your .env file, change from:
DB_HOST=ep-wandering-math-agv6001k-pooler.c-2.eu-central-1.aws.neon.tech
To (remove '-pooler'):
DB_HOST=ep-wandering-math-agv6001k.c-2.eu-central-1.aws.neon.tech
i generated the default migrations and when i try to migrate:
$ php artisan migrate:fresh
INFO Preparing database.
Creating migration table ........................................................................................................... 240.69ms DONE
INFO Running migrations.
0001_01_01_000000_create_users_table ............................................................................................... 240.31ms FAIL
Illuminate\Database\QueryException
SQLSTATE[25P02]: In failed sql transaction: 7 ERROR: current transaction is aborted, commands ignored until end of transaction block (Connection: pgsql, Host:
ep-wandering-math-agv6071k-pooler.c-2.eu-central-1.aws.neon.tech, Port: 5432, Database: neondb, SQL: alter table "users" add constraint "users_email_unique" uni
que ("email"))
at C:\Users\elton\Documents\programming\taskr\backend\vendor\laravel\framework\src\Illuminate\Database\Connection.php:831
827▕ $exceptionType = $this->isUniqueConstraintError($e)
828▕ ? UniqueConstraintViolationException::class
829▕ : QueryException::class;
830▕
➜ 831▕ throw new $exceptionType(
832▕ $this->getNameWithReadWriteType(),
833▕ $query,
834▕ $this->prepareBindings($bindings),
835▕ $e,
1 C:\Users\elton\Documents\programming\taskr\backend\vendor\laravel\framework\src\Illuminate\Database\Connection.php:577
PDOException::("SQLSTATE[25P02]: In failed sql transaction: 7 ERROR: current transaction is aborted, commands ignored until end of transaction block")
2 C:\Users\elton\Documents\programming\taskr\backend\vendor\laravel\framework\src\Illuminate\Database\Connection.php:577
PDOStatement::execute()
I don't know whats the problem, i mean the default migrations should be correct?
Please or to participate in this conversation.