--- title: "setNull Method (int, int, java.lang.String) | Microsoft Docs" ms.custom: "" ms.date: "01/19/2017" ms.prod: sql ms.prod_service: connectivity ms.reviewer: "" ms.technology: connectivity ms.topic: conceptual apiname: - "SQLServerPreparedStatement.setNull (int, int, java.lang.String)" apilocation: - "sqljdbc.jar" apitype: "Assembly" ms.assetid: 43c74e06-2858-49ba-bae7-b88808e5fff4 author: David-Engel ms.author: v-daenge --- # setNull Method (int, int, java.lang.String) [!INCLUDE[Driver_JDBC_Download](../../../includes/driver_jdbc_download.md)] Sets the designated parameter to a null value, given the type and name of the parameter to set. ## Syntax ``` public final void setNull(int paramIndex, int sqlType, java.lang.String typeName) ``` #### Parameters *paramIndex* An **int** that indicates the parameter number. *sqlType* A JDBC type code defined by java.sql.Types. *typeName* A **String** that indicates the fully qualified name of the parameter that is being set. ## Exceptions [SQLServerException](../../../connect/jdbc/reference/sqlserverexception-class.md) ## Remarks This setNull method is specified by the setNull method in the java.sql.PreparedStatement interface. ## See Also [setNull Method (SQLServerPreparedStatement)](../../../connect/jdbc/reference/setnull-method-sqlserverpreparedstatement.md) [SQLServerPreparedStatement Members](../../../connect/jdbc/reference/sqlserverpreparedstatement-members.md) [SQLServerPreparedStatement Class](../../../connect/jdbc/reference/sqlserverpreparedstatement-class.md)