LexikTranslationBundle icon indicating copy to clipboard operation
LexikTranslationBundle copied to clipboard

Update TransUnitRepository.php

Open FolkenFR opened this issue 4 years ago • 3 comments

I use this bundle with an Oracle database and the "in" condition is limited to 1000. So I need to limit the number of ids used with the "in" condition. By the way, limit the number of id isn't a bad choice.

FolkenFR avatar Jan 27 '22 11:01 FolkenFR

@FolkenFR I remember a recent case where I needed an IN condition on an unrelated project, with over 5,000 id's. I worked fine and it saved the day. Is it really a good idea, to limit the IN condition for everyone?

bartmcleod avatar Jan 31 '22 19:01 bartmcleod

From your PR, I also do not see immediately how this code is going to limit $locales to 1000 elements...

bartmcleod avatar Jan 31 '22 19:01 bartmcleod

Applying the domain filter in the query greatly limits the number of identifiers returned by the query on line 225. In my case, the number of ids returned is less than 1000 when a user lists the translations by domain.

FolkenFR avatar Feb 01 '22 08:02 FolkenFR

@FolkenFR I checked out your PR, but tests fail when I do. You probably need to rebase on master

bartmcleod avatar Nov 17 '22 22:11 bartmcleod

Closing because I am not convinced it is a good idea to limit an IN clause to 1000 elements. If anyone thinks this should be re-opened, let me know or if you can, just re-open it with a comment stating why it would be good idea.

bartmcleod avatar Aug 06 '23 15:08 bartmcleod