jssitemlist (outputs a list of Items)
- Organization of this page
Description
This command outputs a list of Items registered in JP1/Service Support to a CSV file. If you cancel the jssitemlist command while it is being executed, the command outputs the data up to that point.
Format
jssitemlist -o Item-details-file-name [-b process-work-board-ID [-pi process-work-board-serial-number]] [-ct start-date-end-date | -r start-date-end-date] [-e] [-a] [-f] [-d]
Required execution permission
Administrator permissions
Storage folder
JP1/SS-path\bin\
Arguments
-o Item-details-file-name
Use 255 bytes or less to specify the name of the Item details file to which you want to output the list of Items registered in JP1/Service Support. You can use an absolute path or a relative path to specify the file name. When you use a relative path, make sure that it will be 255 bytes or less after it is converted to an absolute path. For the file name, you cannot specify a character string beginning with a hyphen (-). Count two bytes for full-width characters in the file name.
An Item details file contains the data of Items in statuses other than Close. If you want to include the data of the Items in the Close status, specify the -a option.
-b process-work-board-ID
Specifies the ID of a process work board if you want to output the data of only the Items in a specific process work board. Use 64 or less half-width alphanumeric characters to specify a process work board ID. If you do not specify this option, the command outputs the data of all Items in the Item management database.
-pi process-work-board-serial-number
Specifies the process work board serial number of an Item if you want to output the data of a specific Item in the process work board specified by the -b option.
When you specify this option, make sure that you also specify the -b option. If you do not specify the -pi option, the command outputs the data of all Items in the process work board specified in the -b option.
For details about process work board serial numbers, see 3.2.2(1) List of Items.
-ct start-date-end-date
Specifies a period in YYYY/MM/DD format to output the data of the Items registered in that period. Insert a hyphen (-) between the start date and the end date.
For start-date and end-date, you can specify dates in the range from 1970/01/02 to 2036/12/31. For start-date, specify a date earlier than end-date.
The descriptions of the start date and the end date are as follows.
- start-date
-
Outputs the data of the Items that were registered on and after this date. If you specify a non-existent date within the specifiable range, the system moves the specified date forward to the next existing date and outputs the data of the Items that were registered on and after that date.
- end-date
-
Outputs the data of the Items that were registered on and before this date. If you specify a non-existent date within the specifiable range, the system moves the specified date back to the closest previous existing date and outputs the data of the Items that were registered on and before that date.
For example, if you specify 2013/04/01-2013/04/07, the command outputs the data of the Items that were registered between 2013/04/01 00:00:00(.000) and 2013/04/07 23:59:59(.999).
If you do not specify the -ct option and the -r option, the command outputs the data of all Items.
-r start-date-end-date
Specifies a period in YYYY/MM/DD format to output the data of the Items updated in that period. Insert a hyphen (-) between the start date and the end date.
For start-date and end-date, you can specify dates in the range from 1970/01/02 to 2036/12/31. For start-date, specify a date earlier than end-date.
The descriptions of the start date and the end date are as follows.
- start-date
-
Outputs the data of the Items that were updated on and after this date. If you specify a non-existent date within the specifiable range, the system moves the specified date forward to the next existing date and outputs the data of the Items that were updated on and after that date.
- end-date
-
Outputs the data of the Items that were updated on and before this date. If you specify a non-existent date within the specifiable range, the system moves the specified date back to the closest previous existing date and outputs the data of the Items that were updated on and before that date.
For example, if you specify 2013/04/01-2013/04/07, the command outputs the data of the Items that were updated between 2013/04/01 00:00:00(.000) and 2013/04/07 23:59:59(.999).
If you do not specify the -ct option and the -r option, the command outputs the data of all Items.
-e
If you specify this option, the command includes the user-customized elements in the Item details file. If you do not specify this option, the command does not include the user-customized elements in the Item details file.
-a
Outputs the data of the Items in all statuses including Close. If you do not specify this option, the command outputs the data of the Items in statuses other than Close.
-f
Overwrites the Item details file.
-d
Outputs the data of only the Items in the Waiting to be deleted status. When you specify this option, body item Editor in the Item details file is changed to Deleter. This lets you check the users who placed Items in the Waiting to be deleted status. In addition, body item Update date and time indicates the date and time when Items were placed in the Waiting to be deleted status. However, note that the command does not output the data of the Items in the target system or process work board in the Waiting to be deleted status to the Item details file. If you want to output the data of the Items in the Close status to the Item details file, specify the -a option as well.
Return values
Return value |
Meaning |
---|---|
0 |
Normal end |
1 |
Abnormal end |
Contents of an Item details file
An Item details file contains data in the following format.
The details about the contents of an Item details file are as follows.
- Header section
-
Output sequence
Header item
Value
1
Product name
JP1/Service Support
2
Version number of the Item details file
The version number of the file is indicated by 6 digits.
3
Character encoding used in the Item details file
Character encoding of output files.
4
Type of data that is output to the Item details file
-
When no extended element exists
ITEMLIST
-
When extended elements exist
ITEMLISTΔExtendedΔData
(Note: Δ indicates a half-width space.)
5
Number of Items in the Close status among the Items that are output to the Item details file
Closed Item Number : number-of-Items
Output example: Closed Item Number : 45
6
Number of Items in statuses other than Close among the Items that are output to the Item details file
Unclosed Item Number : number-of-Items
Output example: Unclosed Item Number : 5
-
- Body section
-
The body section contains the same types of data as output by the jssitemhistory command. For details about the data to be included in the body section, see jssitemhistory (outputs Item history).
Prerequisites for executing the command
-
For details about which services need to be active or inactive when this command is executed, see Status of services when commands are executed in Chapter 12. Commands.
-
Do not execute the following commands while the jssitemlist command is being executed. If you do, the jssitemlist command might fail.
-
jssformdef command
-
jssdelrec command
-
jssdbinit.bat command
-
jssdbrorg.bat command
-
jssdbreclaim.bat command
-
jssdbbackup.bat command
-
jssdbrecovery.bat command
-
jssitemstore command
-
jssitemstoredbexpand.bat command
-
jssitemstoredbsetup.bat command
-
jssrefaclsetup command
-
jssstoreitemdel.bat command
-
-
If you want to execute multiple jssitemlist commands with the -f option, specify a different Item details file name for each command. If you specify the same file name for multiple jssitemlist commands, the contents of the Item details file might become incomplete.
Remarks
-
If you cancel the jssitemlist command by using Ctrl+C while the command is being executed, some Item data might not be output. For this reason, do not cancel the command during execution by using Ctrl+C. If you happen to do so, wait for a while and then re-execute the command.
-
If the data that is output to the Item details file does not contain character strings corresponding to the values of selection codes, the values of selection codes are output to the file without change.
-
In the Item details file, the date and time data before 1970/01/01 23:59:59 (inclusive) and after 2037/01/01 00:00:00 (inclusive) might not be correct.
-
One jssitemlist command can output a maximum of 65,530 Item records. If you want to output 65,531 or more records, specify the -b option or the -r option in the jssitemlist command to narrow down the target range, and execute the jssitemlist command multiple times.
-
If you use the jssitemlist command to output Item information that includes deleted users, the IDs of the deleted users will not be output.
-
If you use the jssitemlist command to output a large amount of Item information, the database work space might be insufficient, and the message "KNAB24002-E: An error occurred in the database of JP1/Service Support. (-713)" might be output. If this occurs, adjust the start date and end date to narrow down the Item information, and then re-execute the command.
-
If the information to be output includes characters that are mapped with UTF-8 but that are not mapped with the character set used in the operating environment, those characters are replaced with question marks (?) in the CSV file output.
Example
The following example shows how to output the data of the Items that were registered between April 1, 2007 and July 31, 2007 to the Item details file (c:\Item\Iteminfo.csv) from the Items in the process work board with ID HQsystem. The Item details file is overwritten.
jssitemlist -o c:\Item\Iteminfo.csv -b HQsystem -r 2007/04/01-2007/07/31 -a -f