public class SQLServerMetaData
extends java.lang.Object
Constructor | Description |
---|---|
SQLServerMetaData(SQLServerMetaData sqlServerMetaData) |
Constructs a SQLServerMetaData from another SQLServerMetaData object.
|
SQLServerMetaData(java.lang.String columnName,
int sqlType) |
Constructs a SQLServerMetaData with the column name and SQL type.
|
SQLServerMetaData(java.lang.String columnName,
int sqlType,
int precision,
int scale) |
Constructs a SQLServerMetaData with the column name, SQL type, precision, and scale.
|
SQLServerMetaData(java.lang.String columnName,
int sqlType,
int precision,
int scale,
boolean useServerDefault,
boolean isUniqueKey,
SQLServerSortOrder sortOrder,
int sortOrdinal) |
Constructs a SQLServerMetaData.
|
Modifier and Type | Method | Description |
---|---|---|
java.lang.String |
getColumName() |
Returns the column name.
|
int |
getPrecision() |
Returns the precision of the type passed to the column.
|
int |
getScale() |
Returns the scale of the type passed to the column.
|
SQLServerSortOrder |
getSortOrder() |
Returns the sort order.
|
int |
getSortOrdinal() |
Returns the sort ordinal.
|
int |
getSqlType() |
Returns the java sql type.
|
boolean |
isUniqueKey() |
Returns whether the column is unique.
|
boolean |
useServerDefault() |
Returns whether the column uses the default server value.
|
public SQLServerMetaData(java.lang.String columnName, int sqlType)
columnName
- the name of the columnsqlType
- the SQL type of the columnpublic SQLServerMetaData(java.lang.String columnName, int sqlType, int precision, int scale)
columnName
- the name of the columnsqlType
- the SQL type of the columnprecision
- the precision of the columnscale
- the scale of the columnpublic SQLServerMetaData(java.lang.String columnName, int sqlType, int precision, int scale, boolean useServerDefault, boolean isUniqueKey, SQLServerSortOrder sortOrder, int sortOrdinal) throws SQLServerException
columnName
- the name of the columnsqlType
- the sql type of the columnprecision
- the precision of the columnscale
- the scale of the columnuseServerDefault
- specifies if this column should use the default server value; Default value is false.isUniqueKey
- indicates if the column in the table-valued parameter is unique; Default value is false.sortOrder
- indicates the sort order for a column; Default value is SQLServerSortOrder.Unspecified.sortOrdinal
- specifies ordinal of the sort column; sortOrdinal starts from 0; Default value is -1.SQLServerException
- when an error occurspublic SQLServerMetaData(SQLServerMetaData sqlServerMetaData)
sqlServerMetaData
- the object passed to initialize a new instance of SQLServerMetaDatapublic java.lang.String getColumName()
public int getSqlType()
public int getPrecision()
public int getScale()
public boolean useServerDefault()
public boolean isUniqueKey()
public SQLServerSortOrder getSortOrder()
public int getSortOrdinal()
Copyright © 2018 Microsoft Corporation. All rights reserved.