3.4

Message Types
Message types
Outboundmessage(1) Processing request
messageInboundmessage(2) Processing result
message(A) Processing result
notification message(B) Output message…

For screen [R]For printer…

a

For printer [P], [A]For screen (non-inquiryresult)…

b

For screen [C]

Successful…

c

For screen [M]

Error

…

Message for user's own interface…

For screen(inquiry result)(3) Message for filingManagement document(CSV format)

For screen [R]dUser's own interface[T]…

For filing [F]Management document(Fixed-length delimiterformat)…

For printer [P]in-storage message…

For storage [U](Note) See Table 3.4.1(4) Message for storage*[Message type] indicates a value specified in Message Control Information in the output common
fields in a message transmitted from the NACCS Center server to a user system (inboundmessage).
The purpose of classifying details of messages in NACCS EDI messages
for printer or screen is that when looking at the message on software package provided by NACCS,
the software package can identify whether images should be displayed in the template for the printeror in the template for the screen. When carrying out in-house development of software which uses
gateway connection, it is not necessary to be aware of this classification.
e.g.) For Printer [P]: the software package combines printing templates, which corresponds to themessage, and displays printing image on the user computer.
e.g.) For printer [C]: the software package combines screen templates which corresponds to themessage and displays a screen image on the user computer.

3-4-1

(1)

Processing request message
This message is sent by the user to the NACCS Center server to request processing.

(2) Processing result message (See "Appendix 5 Details of Processing Result Messages")(A) Processing result notification message (for screen [R])This message notifies a user whether or not a processing request message (non-inquiryprocedure) sent by the user has been processed successfully.
If the processing in response to the message has been completed successfully in the processing,a processing result notification message indicating successful completion is returned, while if theprocessing has failed, a processing result notification message indicating processing failed isreturned.
If an error occurs before the processing takes place in the core processing system, anotherprocessing result notification message (for common errors) is returned. (For common errors, see"Appendix 6 Codes".)(B) Output messages
This message is returned after completion of processing in the core processing system in
response to a processing request message sent by the user to the NACCS Center server.
a. Output messages (for printer [P], [A])This message type is to prompt the printer to print records when the user uses the packaged
software provided by NACCS Center.
This is used for the software package to change storage formats to store the message according
to Message Types (For printer [P], [A]), so it is not necessary for users to be aware of thedifference between [P] and [A]. (Message Type [P]: Text format, Message Type [A]: CSV format)e.g.) For printer [P]: The software package stores the messages in text format.
e.g.) For screen [A]: The software package stores the messages in CSV format.
Figure 3.4.1 shows the flow of output messages (for printer).

(1) Processing request message(2)-A Processing result notification
message(2)-B-a Output information message(for printer)
Computer

Printer

User system

NACCS Center server

Figure 3.4.1 Flow of Output Information (for Printer)

3-4-2

b. Output information messages (non-inquiry result) (for screen [C])This message type is to prompt display of a message text on the screen when the user uses thepackaged software provided by NACCS Center.
Figure 3.4.2 shows a flow of output information messages (non-inquiry result) (for screen).
(1) Processing request message(2)-A Processing result
notification message

Computer(2)-B-b Output information message(for screen)

NACCS Center server

User system

Figure 3.4.2 Flow of Output Information Messages (Non-inquiry Result) (for Screen)c. Output information messages (inquiry result) (for screens [M], [R])This type of message is sent after completion of processing in the core processing system inresponse to an inquiry request sent by the user to NACCS Center. There are two types of inquiry
procedure: one for successful completion and the other for an error.
(i)When the core processing system successfully completes procedure processing
An information message for screen (Message Type [M]) is output.
This message contains the processing result code indicating successful completion, and theinquiry result. Also the software package displays the processing result screen and theprocessing result code indicating a successful completion.
The following shows the flow of messages in this case.
(ii)When the core processing system stops due to error
A processing result notification message (Message Type [R]) is output.
This message contains only the processing result code indicating error, and the software
package displays the input screen and the processing result code indicating error.

(1) Processing request message(2)-B-c Output information message(inquiry result) (For screen)
ComputerUser system

NACCS Center server

Figure 3.4.3 Flow of Output Information Messages (Inquiry Result) (for Screen)

3-4-3

d. Output messages (messages for user's own interface) (user's own interface [T])This type of message is to be imported into and used on the user's own system.
Therefore, when looking at the message on the software package, since there is nocorresponding template (for screen and for printer), the message will not be displayed as ascreen image or printed image. (The message is displayed in text data.)
Refer to "Appendix Table 6.8 Output Information Code List" for types of output information
include the following:(3) Message for filing (management documents) (filing [F], printer [P])This message is used to transfer a management document from the NACCS Center server to thepackaged software. A Maximum size of messages allowable for transmission is 30,000,000 bytes
after file compression.
Table 3.4.1 shows message types and formats used in the NACCS system.
Table 3.4.1

Outline of File Fetching Messages

FormatEditing, etc.

Message TypeFor filing [F]CSVRemarks

Messages can be edited by For file names whenusers using commerciallymessages are stored inavailable spreadsheet

external files, refer tosoftware, etc.

"Operation Manual for
NACCS Packaged Software."

For printer [P]Fixed-length

The software package

delimiter

combines printing
templates and print
records.

(4) Message for storage (in-storage message) (for storage [U])This type of message contains a processing result that is generated when "Declaration on cargotransportation" or "Declaration during business hours" procedures is processed. In another case, thistype of message contains a processing result that is generated when procedures relating to therelevant ministerial ordinances are processed through the single window procedure. This type ofmessage is generated only in interactive processing mode.
If processing is executed when the user's computer is not connected to the NACCS Center server, aprocessing result is stored in the NACCS Center server along with an output information message(for printer), and, therefore, the user must retrieve such in-storage message and output information
message (for printer) from the NACCS Center server when connecting to NACCS.
If processing is executed when the user's computer is connected to the NACCS Center server, anin-storage message is automatically sent to the user system.

3-4-4

(For reference) Format of transmission of management documents
1. Transmission and file formats
Management documents are sent primarily in CSV format, allowing the user to edit or perform
calculations on such documents using commercially available spreadsheet software etc. Some
types of documents are sent in the fixed-length delimiter format which is suitable for printing.
For the output format, refer to "Appendix Table 6.9.2 List of Private Management Document
Information."
In addition, for details of the message format for management documents, refer to "6. Retrieval ofManagement Document Information."
CSV format:
A text-based format. Data elements are delimited by ',' (comma) and each line ends with CRLF
codes. Figure 3.4.4 describes an example CSV format file.

XXXXXXXXXXXXXXXXXX……XXXXXXX <CRLF>(output common fields - 398 bytes)

輸入申告一覧表<CRLF>(title)

許可日,承認日,申告日,申告番号 <CRLF> (cell element)
AAAAAAAAAA , BBBBBBBBBB , CCCCCCCCCC , DDDDDDDDDD <CRLF>(values in 1st row)

EEEEEEEEEE , FFFFFFFFFF , GGGGGGGGGG , HHHHHHHHHH <CRLF>(values in 2nd row)

Figure 3.4.4 CSV Format File
CSV stands for "Comma Separated Value". This file format uses ',' (comma) as a data element
separator. This format is widely used in spreadsheet and database software products, which allow
the user to directly import data in CSV format. Note that special codes such as commas anddouble quotes are treated slightly different depending on the spreadsheet software used.

2. Edit and print(1) Management documents (CSV format) (for filing [F])a. Management documents are converted into CSV format on the NACCS Center server anddelivered to users.
b. The user can edit, modify or print management documents received in CSV format using
commercially available spreadsheet software etc.
(2) Management documents (fixed-length delimiter format) (for printer [P])a. Management documents are converted into the fixed-length delimiter format on the NACCS
Center server before being sent to the user.
b. The software package opens the printing templates linked to the output message, anddisplays the printing image. When necessary, the user can print records using the printfunction of the software package.

3. Spreadsheet software used for handling management documents (CSV format) (for filing [F])Since the data in CVS format are treated slightly different depending on the spreadsheet software
used, NACCS creates data in CSV format supported by "Microsoft Excel."

3-4-5