| title | setCatalog Method (SQLServerConnection) |
|---|---|
| description | setCatalog Method (SQLServerConnection) |
| author | David-Engel |
| ms.author | davidengel |
| ms.date | 01/19/2017 |
| ms.service | sql |
| ms.subservice | connectivity |
| ms.topic | reference |
| apilocation | sqljdbc.jar |
| apiname | SQLServerConnection.setCatalog |
| apitype | Assembly |
[!INCLUDEDriver_JDBC_Download]
Sets the given catalog name to select a subspace of this SQLServerConnection object's database in which to work.
public void setCatalog(java.lang.String catalog)
catalog
A String that contains the catalog name.
This setCatalog method is specified by the setCatalog method in the java.sql.Connection interface.
The catalog argument is escaped by the [!INCLUDEjdbcNoVersion] automatically. Using this method sets the catalog property for the Connection object. It is not set implicitly in any other way.