Copy Sheet

Operation Name

Copy Sheet

Function Overview

Copies the sheet from the specified Excel workbook.

Properties

For details on use of variables, refer to “Variables”.
Basic settings
Item name Required/Optional Use of variables Description Remarks
Name Required Not available Enter the name to show on the script canvas.  
Required settings
Item name Required/Optional Use of variables Description Remarks
Copy source file Required Available Enter the source path of Excel file.

You can click [Browse] button to launch file chooser and find the file.
  • Specify a file path of Excel workbook with “.xlsx” or “.xlsm” extension.
  • Specify the file path as an absolute path of DataSpider File System.
  • Except for the path separator “/”, restricted characters of DataSpider File System cannot be used.
Copy destination file Required Available Enter the destination path of the Excel file.
You can even specify a file same as the source Excel file.

You can click [Browse] button to launch file chooser and find the file.
  • Specify a file path of Excel workbook with “.xlsx” or “.xlsm” extension.
  • Specify the file path as an absolute path of DataSpider File System.
  • Except for the path separator “/”, restricted characters of DataSpider File System cannot be used.
  • Excel workbook will be newly created when the specified file does not exist.
Sheet list Optional - Specify the sheet to be copied.
  • When omitted, the all sheets will be copied.
Sheet list/Copy source sheet name Required Available Select or enter the source sheet available in the Excel file specified in [Copy source file].
  • Case-insensitive.
Sheet list/Copy destination sheet name Required Available Enter the copied sheet name to the Excel file specified in [Copy destination file].
  • Case-insensitive.
  • Enter a sheet name that is not available in the Excel file specified in [Copy destination file].
Transaction
Item name Required/Optional Use of variables Description Remarks
Execute transaction processing Optional Not available Select whether or not to execute transaction processing.
  • [Checked]:
    Transaction processing will be executed.
  • [Not checked]: (default)
    Transaction processing will not be executed.
Refer to “Transaction of file category adapters” for more details.
 
Comment
Item name Required/Optional Use of variables Description Remarks
Comment Optional Not available You can write a short description of this adapter.
The description will be reflected in the specifications.
 

Schema

Input schema

None.

Output schema

None.

Transaction

Transaction is supported.

Transaction is enabled only when [Execute transaction processing] of [Transaction] is checked.

PSP Usage

PSP is not supported.

Available Component Variables

Component variable name Description Remarks
message_category When an error occurs, the corresponding message code's category is stored.
  • Default value is null.
message_code When an error occurs, the corresponding message code is stored.
  • Default value is null.
message_level When an error occurs, the corresponding message code's severity is stored.
  • Default value is null.
error_type When an error occurs, the error type is stored.
  • Default value is null.
  • The error type will be in the following format.
    Example: “java.io.FileNotFoundException”
  • The contents that will be stored may vary depending on DataSpider Servista versions.
error_message When an error occurs, the error message is stored.
  • Default value is null.
  • The contents that will be stored may vary depending on DataSpider Servista versions.
error_trace When an error occurs, the error's trace information is stored.
  • Default value is null.
  • The contents that will be stored may vary depending on DataSpider Servista versions and client applications.

Specification Limits

Major Exceptions

Exception name Cause Solution
InvalidPropertyConfigurationException
File path is not specified.
Either [Copy source file] or [Copy destination file] is not specified. Specify [Copy source file] and [Copy destination file].
InvalidPropertyConfigurationException
Unsupported Excel workbook is specified.
Unsupported Excel workbook is specified as [Copy source file] or [Copy destination file]. Specify an Excel workbook compatible to [Copy source file] and [Copy destination file].
FileIsDirectoryException The path entered in [Copy source file] or [Copy destination file] is directory. Enter a file path in [Copy source file] and [Copy destination file].
FileIsLockedException The file specified in [Copy source file] or [Copy destination file] is being locked. Unlock it from Explorer or CLI.
java.io.FileNotFoundException The file specified in [Copy source file] does not exist. Check [Copy source file].
java.io.FileNotFoundException
Some other process is using the file.
The file specified in [Copy source file] or [Copy destination file] is being used by some other process. Make sure that it is not being used by some other process.
SheetNotFoundException
The sheet name that does not exist is specified.
The sheet specified in [Copy source sheet name] does not exist. Specify an existing sheet name in [Copy source sheet name].
SheetAlreadyExistsException
Specified sheet already exists.
The sheet specified in [Copy destination sheet name] already exists. Specify an not existing sheet name in [Copy destination sheet name].

Notes