freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: Mike Sela <mikesela AT gmail.com>
- To: freetds AT lists.ibiblio.org
- Subject: [freetds] SQL Server parameter substitution
- Date: Mon, 27 Feb 2012 15:53:54 -0800
Hi,
I'm using FreeTDS on Ubuntu (through pymssql and SQLAlchemy) to connect to
my SQL Server and I'm running into an issue where I can't seem to pass
parameterized SQL statements through to SQL Server. I can create my nice
neat parameterized statements in SQL Alchemy that look like this:
SELECT * FROM Customers WHERE CustomerId = :CustomerId;
but by the time it gets to the DB, it looks like this:
SELECT * FROM Customers WHERE CustomerId = 572;
The actual parameter substitution appears to be occurring in the pymssql
layer, but they tell me that that's because of a limitation in FreeTDS,
where parameterized SQL is not handled. Is that true?
This creates a problem for us because every statement is fairly unique
(since the ids are embedded in the SQL) and thus we rarely get to re-use
execution plans.
Please let me know if my understanding about parameterized SQL not being
supported by FreeTDS is correct.
Many thanks!
-Mike
-
[freetds] SQL Server parameter substitution,
Mike Sela, 02/27/2012
-
Re: [freetds] SQL Server parameter substitution,
Ken Collins, 02/27/2012
- Re: [freetds] SQL Server parameter substitution, Randy Syring, 02/27/2012
-
Re: [freetds] SQL Server parameter substitution,
James K. Lowden, 02/27/2012
- Re: [freetds] SQL Server parameter substitution, Frediano Ziglio, 02/28/2012
-
Re: [freetds] SQL Server parameter substitution,
Ken Collins, 02/27/2012
Archive powered by MHonArc 2.6.24.