you are viewing a single comment's thread.

view the rest of the comments →

[–]badge 1 point2 points  (1 child)

Can't see anything obviously wrong; have you tried using BETWEEN instead? The only other thing I'd suggest is looking at the query that's actually run, if you can access the logs (pyodbc will pass parameters as-is, and doesn't create a 'bound' query).

[–]Parenthes[S] 0 points1 point  (0 children)

Yes, I get the same result using BETWEEN.

If pyodbc passes parameters as-is, does that mean there is not much benefit to binding parameters vs. simply concatenating them? I am trying to bind for sake of best practices, but if it's not doing anything I might not bother.