Comment 5 for bug 691836

Revision history for this message
Geert JM Vanderkelen (geertjmvdk) wrote :

I think an easier fix (maybe even faster) is to first replace all %s by something else:

                elif isinstance(params, (list,tuple)):
                    stmt = stmt.replace(b'%s',b'%mys')
                    for p in self._process_params(params):
                        stmt = stmt.replace(b'%mys',p,1)

I'm using '%mys' because that would (hopefully) never or rarely clash.
What you think?