Each database driver behaves a bit differently when it comes to JSON properties.
MikroORM tries to unify the experience via JsonType.
This type will be also used if you specify
Support for querying by JSON object properties was added in v4.4.2
We can query by JSON object properties easily:
Will produce following query (in postgres):
All drivers are currently supported (including sqlite and mongo). In postgres we also try to cast the value if we detect number or boolean on the right-hand side.