SQLServerBulkBatchInsertRecord
, SQLServerBulkCSVFileRecord
public interface ISQLServerBulkRecord
SQLServerBulkCommon
ClassModifier and Type | Method | Description |
---|---|---|
void |
addColumnMetadata(int positionInFile,
String name,
int jdbcType,
int precision,
int scale) |
Adds metadata for the given column in the file.
|
void |
addColumnMetadata(int positionInFile,
String name,
int jdbcType,
int precision,
int scale,
DateTimeFormatter dateTimeFormatter) |
Adds metadata for the given column in the file.
|
DateTimeFormatter |
getColumnDateTimeFormatter(int column) |
Retreives
dateTimeFormatter for the given column |
String |
getColumnName(int column) |
Get the name of the given column.
|
Set<Integer> |
getColumnOrdinals() |
Get the ordinals for each of the columns represented in this data record.
|
int |
getColumnType(int column) |
Get the JDBC data type of the given column.
|
int |
getPrecision(int column) |
Get the precision for the given column.
|
Object[] |
getRowData() |
Gets the data for the current row as an array of Objects.
|
int |
getScale(int column) |
Get the scale for the given column.
|
boolean |
isAutoIncrement(int column) |
Indicates whether the column represents an identity column.
|
boolean |
next() |
Advances to the next data row.
|
void |
setTimestampWithTimezoneFormat(String dateTimeFormat) |
Set the format for reading in dates from the file.
|
void |
setTimestampWithTimezoneFormat(DateTimeFormatter dateTimeFormatter) |
Set the format for reading in dates from the file.
|
void |
setTimeWithTimezoneFormat(String timeFormat) |
Set the format for reading in dates from the file.
|
void |
setTimeWithTimezoneFormat(DateTimeFormatter dateTimeFormatter) |
Set the format for reading in dates from the file.
|
Set<Integer> getColumnOrdinals()
String getColumnName(int column)
column
- Column ordinalint getColumnType(int column)
column
- Column ordinalint getPrecision(int column)
column
- Column ordinalint getScale(int column)
column
- Column ordinalboolean isAutoIncrement(int column)
column
- Column ordinalObject[] getRowData() throws SQLServerException
SQLServerException
- If there are any errors in obtaining the data.boolean next() throws SQLServerException
SQLServerException
- If there are any errors in advancing to the next row.void addColumnMetadata(int positionInFile, String name, int jdbcType, int precision, int scale, DateTimeFormatter dateTimeFormatter) throws SQLServerException
positionInFile
- Indicates which column the metadata is for. Columns start at 1.name
- Name for the column (optional if only using column ordinal in a mapping for SQLServerBulkCopy operation)jdbcType
- JDBC data type of the columnprecision
- Precision for the column (ignored for the appropriate data types)scale
- Scale for the column (ignored for the appropriate data types)dateTimeFormatter
- format to parse data that is sentSQLServerException
- when an error occursvoid addColumnMetadata(int positionInFile, String name, int jdbcType, int precision, int scale) throws SQLServerException
positionInFile
- Indicates which column the metadata is for. Columns start at 1.name
- Name for the column (optional if only using column ordinal in a mapping for SQLServerBulkCopy operation)jdbcType
- JDBC data type of the columnprecision
- Precision for the column (ignored for the appropriate data types)scale
- Scale for the column (ignored for the appropriate data types)SQLServerException
- when an error occursvoid setTimestampWithTimezoneFormat(String dateTimeFormat)
dateTimeFormat
- format to parse data sent as java.sql.Types.TIMESTAMP_WITH_TIMEZONEvoid setTimestampWithTimezoneFormat(DateTimeFormatter dateTimeFormatter)
dateTimeFormatter
- format to parse data sent as java.sql.Types.TIMESTAMP_WITH_TIMEZONEvoid setTimeWithTimezoneFormat(String timeFormat)
timeFormat
- format to parse data sent as java.sql.Types.TIME_WITH_TIMEZONEvoid setTimeWithTimezoneFormat(DateTimeFormatter dateTimeFormatter)
dateTimeFormatter
- format to parse data sent as java.sql.Types.TIME_WITH_TIMEZONEDateTimeFormatter getColumnDateTimeFormatter(int column)
dateTimeFormatter
for the given columncolumn
- Column ordinalCopyright © 2018 Microsoft Corporation. All rights reserved.