MultiDelimiter Project
The MultiDelimiter project contains two adapter configurations: MultiDelimReader.adfilesmodel and MultiDelimWriter.adfilesmodel. The sample project shows how the adapter handles files with multiple delimiters.
In MultiDelimReader.adfilesmodel, Publication Service parses the multidelim.txt file and publishes each line with a pair of commas as multiple delimiters. To enable Publication Service to parse the multidelim.txt file, the read schema defines three file records: Customer, Business and Contact. The Customer record is configured with a comma as the delimiter between fields. The Business record is configured with two percentage characters (%%) and the Contact record is configured with two hyphens and two asterisks (-**-) as the delimiters between each field.
In MultiDelimWriter.adfilesmodel, Subscription Service receives each message, formats it and writes it to the outmultidelim.txt file using a semi colon as a single delimiter. Subscription Service is configured with a single delimiter character between fields.
For example, the line in the input file( Business%% B0001%% Application Integration%% REUTERS) is changed as (Business;B0001;Application Integration;REUTERS) in the output file.