alkem-io / server

Core server in the Alkemio platform, offering a GraphQL api for interacting with the logical domain model.
http://alkem.io
European Union Public License 1.2
24 stars 4 forks source link

Fix storage query #4205

Closed ccanos closed 23 hours ago

ccanos commented 3 days ago

This typeorm query: image was turned into this:

image

I have just removed the useless selected columns to retrieve only the SUM(size). image


Has been difficult to reproduce in localhost, because we don't have ONLY_FULL_GROUP_BY enabled in our local mysql container.

I have tried to enable it with this command:

SET session sql_mode='ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION'

but that was not enough - not sure why - SELECT @@sql_mode; was still the same.

The other values STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION are the default ones for our local mysql server, but I would like to run SELECT @@sql_mode; on all the environments and make sure that we configure all the environments the same way including local.