Skip to content

Latest commit

 

History

History
30 lines (25 loc) · 1.84 KB

File metadata and controls

30 lines (25 loc) · 1.84 KB
title SQLFreeStmt | Microsoft Docs
ms.custom
ms.date 11/23/2015
ms.prod sql
ms.prod_service database-engine, sql-database, sql-data-warehouse, pdw
ms.reviewer
ms.technology native-client
ms.topic reference
apitype DLLExport
helpviewer_keywords
SQLFreeStmt function
ms.assetid d9666d0b-3446-480e-bf1a-10b01213e411
author markingmyname
ms.author maghan
monikerRange >=aps-pdw-2016||=azuresqldb-current||=azure-sqldw-latest||>=sql-server-2016||=sqlallproducts-allversions||>=sql-server-linux-2017||=azuresqldb-mi-current

SQLFreeStmt

[!INCLUDEappliesto-ss-asdb-asdw-pdw-md]

Generally
SQLFreeStmt is not recommended in ODBC 3.0 and later. However if the application needs to reuse the statement you should still use SQLFreeStmt with the SQL_RESET_PARAMS and SQL_UNBIND options). You might also use SQLCloseCursor, SQLBindParameter, SQLBindCol, SQLSetDescField, and SQLFreeHandle to replace or duplicate the function of SQLFreeStmt and should use them instead.

In general, it is more efficient to reuse statements than to drop them and allocate new ones. However in some situations, like the reusing of statements, SQLFreeStmt still must be used.

See Also

SQLFreeStmt Function
ODBC API Implementation Details