How is the sqlalchemy's outptut of parameters generated? It has the wrong value in it.
I find it interesting that 99,997 values are correct on a 100,000 parameter query and 50,000 parameters works sometimes but not always. It implies that this is a bug somewhere, like a race condition, rather than a hard limit that is being breached. For what it's worth MySQL has no limit on IN queries (other than max packet size). Anyway I shall leave it here. It's taken me a lot longer to create a test case and investigate this issue than it took me to work around it! Ta, Jon. On May 29, 4:34 pm, "Michael Bayer" <mike...@zzzcomputing.com> wrote: > There is nothing special about SQLAlchemy's handling of many parameters > versus a few, and it's likely a limiation of the IN clause as implemented > on those backends. IN does not support arbitrarily large numbers of > parameters. On Oracle for example the limit is 1000. If you need to do > a large number of IN parameters, you need to batch your queries such that > the size of the IN clause is limited. > > Jonathan Marshall wrote: > > > I have an automatically generated query that occasionally generates a > > huge number of parameters (50,000+). Sometimes Sqlalchemy does not > > correctly serialise the parameters. If I have 50,000 parameters often > > one is incorrect, for 100,000 parameters usually 3 are incorrect. More > > parameters seems to correlate with a higher chance of a problem > > occurring. > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalchemy@googlegroups.com To unsubscribe from this group, send email to sqlalchemy+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en -~----------~----~----~----~------~----~------~--~---