Section 5.2 SI Batch File Layout File Transfer Function SI BATCH FILE LAYOUT INTRODUCTION: The SI File Transfer function is available to participants to upload the Settlement Instruction Batch File to CCASS. The function helps participants with high transaction volumes to avoid duplicating efforts in manually rekeying SIs into CCASS. This section shows the SI batch file layout adopted by CCASS. DESIGN STANDARD: a) All interchange files are of fixed length records. If the total number of bytes in a record is less than the record length, the record will be packed with spaces to make up the length. Every record must have a record delimiter of carriage return and line feed (ASCII hexadecimal value X 0D0A ) at the end. The characters that can be contained in the file are as follows. - digit : 0 to 9 - alphabets : a to z, A to Z - special symbols : SPACE / + -? : ( ),. - record delimiter of carriage return and line feed - a 1-character End-of-File Marker at the end of file (normally ASCII hexadecimal value X 1A ) b) All interchange files are sequential files. There are two categories of records: detail and control records. Detail records contain user information. A record checksum is calculated for each detail record by summing the data contents of essential numeric fields. It is calculated by the sender and checked by the receiver. Control headers contain information such as participant ID, file name, etc., relevant to the file as a whole. Control trailers further protect the file using record counts and hash totals. Should there be any inconsistency in the record checksums, record counts or hash totals, the whole file will be discarded. Different types of records are indicated by the first byte in the records. c) The maximum length of the record checksum in the detail record, the count of detail records and hash totals in the control trailer record are all confined to the data size value specified in the data size column of the record layout. The implied decimal point of a numeric field, as well as the sign, if any, is ignored. Should overflow occur, the leading digit will be discarded. Note that the sum of all record checksums in the control trailer record is the sum of the 12-digit record checksums (with leading digit discarded) of all detail records. d) The maximum size of the batch file is limited to 2 mega bytes or 7002 lines including the header and trailer control records. Batch file with file size or number of lines exceeded this limit will be rejected CCASS Terminal User Guide - For Participants 05/2012 5.2.1
Section 5.2 SI Batch File Layout SETTLEMENT INSTRUCTION BATCH FILE This file contains the detailed information of SIs prepared by participants internal system, which will be uploaded to the CCASS host computer for SI batch file input, deletion or revocation processing. Each record contains 280 bytes, followed by a 2-byte record delimiter. Data item Data size Remarks Control Record Record type X(1) 0 = control header File Indicator 9(4) Mandatory, unique indicator assigned by participant, cannot be re-used within same day Participant ID X(6) Must input, if Sender BIC field is blank Sender BIC X(8) Optional field - Default as blank Participant own file reference X(15) File transmission date 9(8) YYYYMMDD File name X(15) SI BATCH INPUT Filler X(223) Spaces Detail Record Record type X(1) 1 = detail records for SI input Internal transaction reference X(10) Settlement date 9(8) YYYYMMDD Counterparty ID X(6) Must input, if Counterparty BIC field is blank Counterparty BIC X(8) Optional field - Default as blank Stock code 9(5) Even with ISIN entered. "00000" should be entered for numeric field validation. ISIN X(12) Optional field - Default as blank Instruction type X(1) R = Receive D = Deliver Quantity of shares 9(11) Money value of shares 9(11)V9(2) Settlement a/c X(8) If a/c no. has less than 8 digits, it should be padded with leading blank spaces or zeroes. E.g. A/C 1 should be formatted as 1 (7 spaces + 1 ) or 00000001. Must not be any SSA with Statement Service (account number starting from 21 onwards) whose Affirmation Requirement is set to Yes for Delivering SI (i.e. Instruction Type is D ). Client account number X(15) 5.2.2 CCASS Terminal User Guide - For Participants 05/2012
Section 5.2 SI Batch File Layout Data item Data size Remarks Client name X(15) Payment instruction X(1) D = DVP, F = FOP, R = RDP SI purpose indicator X(1) C = broker-custodian transaction, L = stock borrowing/lending, P = stock pledging, R = return/recall, M = portfolio movement, Blank DI required indicator X(1) Y = yes, N = no Remarks 1 Remarks 2 SI Linkage Reference X(40) X(40) X(15) Record checksum 9(12) Sum of settlement date, stock code, quantity & money value of shares Hold matched SI indicator X(1) Y = yes, N or blank space = no Processing reference X(40) Settlement Currency X(3) HKD, CNY, USD or Blank If blank, the settlement currency will be defaulted as the same value of the trading currency of the stock. If the payment instruction of the SI is FOP, only blank or the same value of the trading currency of the stock will be allowed by the system. Filler X(13) Spaces Record type X(1) 3 = detail records for SI deletion / revocation SI Input Number X(9) Filler X(270) Spaces Control Record Record type X(1) 2 = control trailer Total number of detail records 9(3) Total number of type 1 and type 3 records Sum of all stock codes 9(7) Sum of all stock codes of record type 1 Sum of all quantities 9(14) Sum of all quantities of record type 1 Sum of all money values 9(16) Sum of all money values of record type 1 Sum of all record checksums 9(17) Sum of all record checksums of record type 1 Filler X(222) Spaces CCASS Terminal User Guide - For Participants 05/2012 5.2.3