BAI File Parser
In this article
Overview
Flattening the text data in a file.
Reads the file(.bai extensions) from the binary input view
Groups the records basing on the file header(01), group header(02) , account identifier(03)
Writes as csv data format in to the output view.
The count of lines for each group will be equal to the number of transaction lines apart from the lines contains only comments(The lines which does not contain type type codes).
Merged Lines: Some of the Account(03) and/or Transaction(16) lines may be merged in the input. These lines will be divided and processed accordingly.
Â
Detailed description:
Reads the file from the binary input view.
Removes slash ( '/') at end of each line from the input line before processing.
Groups the transaction records(16 or 88) basing on the file header(01), group header(02) , account identifier(03)Â
If the type code not present in the transaction records(16 or 88), then considering the values in this record as comment fields.
If the type code not present in the transaction record -88, and previous transaction record code is 16, then considering the values in this record as comment fields for the previous transaction record as 88 is the continuation record.
Converts date fields into yyyy-mm-dd and time fields into HH:MM.
Date Fields: fileHeader_FileCreationDate, groupHeader_AsofDate,value_date
Time fields: fileHeader_FileCreationTime, groupHeader_AsofTime,value_time
Note:
Ignoring the Record Codes in each line while writing to the output view.Â
As a file contains only one file header, the 01-File Header values appended for each line in the output data.Â
The count of lines for each group will be equal to the number of transaction lines apart from lines containing comments.
Each line should contain details of Record Codes 01,02,03 and a transaction detail line. Where the values for record code will be unique for each file, the values for group header(02) and account identifier(03) may change.
Snap Type
BAI File Parser is a custom parser snap to parse the incoming data from .bai files to csv data format.
Prerequisites
None.
Limitations and Known Issues
None.
Snap Views
Input
This Snap has at exactly one document input view. Each document contains data in the form of text. The file extension is .bai .
Output
This Snap has exactly one document output view. Each document contains corresponding response in the form of csv data.
Error
This Snap has at most one document error view and produces zero or more documents in the view. Each document contains the corresponding error record if snap is not able to process data.
Snap Settings
Label required | The name for the Snap. You can modify this to be more specific, especially if you have more than one of the same Snap in your pipeline. |
Snap Execution optional | Specifies the execution type:
Default value: Execute only  |
Snap Pack History
Â
Have feedback? Email documentation@snaplogic.com | Ask a question in the SnapLogic Community
© 2017-2024 SnapLogic, Inc.