-
Notifications
You must be signed in to change notification settings - Fork 179
Closed
Labels
🐛 tag: bugThis is a bug.This is a bug.
Description
After a fresh install and composer update it's not possible to retrieve index page and admin page because "=" operator on json column in sql query does not exist
Details
| Relevant Bolt Version | 4.0
| Install type | Composer install
| BC Break | yes (documentation talk about postgresql support)
| PHP version | 7.3 (docker-compose provided)
| Web server | Nginx [docker-compose provided]
Reproduction
composer create-project bolt/project myproject
sample of docker-compose.yml
database:
image: postgres:12-alpine
env_file:
- .env
environment:
- POSTGRES_DB=${DATABASE_NAME}
- POSTGRES_PASSWORD=${DATABASE_PASSWORD}
- POSTGRES_USER=${DATABASE_USER}
volumes:
- db-data:/var/lib/postgresql/data:rw
ports:
- target: 5432
published: 5432
protocol: tcp
php/Dockerfile
...
RUN extBuildDeps=" \
...
libpq-dev \
"; \
...
docker-php-ext-install \
...
pdo_pgsql \
...
config/packages/doctrine.yaml
parameters:
# Adds a fallback DATABASE_URL if the env var is not set. This allows you
# to run cache:warmup even if your environment variables are not available
# yet. You should not need to change this value.
env(DATABASE_DRIVER): 'pdo_pgsql'
env(DATABASE_URL): ''
doctrine:
dbal:
charset: utf8
url: '%env(resolve:DATABASE_URL)%'
driver: '%env(resolve:DATABASE_DRIVER)%'
Launch containers
docker-compose up -d
Setup
docker-compose exec php bin/console bolt:setup
# with fixtures
Bug summary
Operator "=" on json column in sql query does not exist on Postgres
Specifics
SQLSTATE[42883]: Undefined function: 7 ERROR: operator does not exist: json = unknown
LINE 1: ..._ ON b1_.id = b3_.translatable_id WHERE b3_.value = $1 AND b...
^
HINT: No operator matches the given name and argument types. You might need to add explicit type casts.
Expected result
Welcome page
Actual result
Error page
Metadata
Metadata
Assignees
Labels
🐛 tag: bugThis is a bug.This is a bug.