Flat File Schema

I am creating a FlatFile Schema based on the information provided by the source sytem.
They did specify the type of the field(Char/numeric).In the schema Under Record definition I am creating the Field definitions accordingly to the specification document.I am just wondering, Can we perform a test by running the file with source data against the
Schema we have to validate the DataTypes coming in or Do I need to handle it in the flow service?
By the way I used the Validator Property and i tested with sample data and it worked the way it supposed
to be.In the similar lines I am just wondering can it be done to vaildate the data types?
I do see in the properties tab property called DataType but I wasnt able to figure it out and documentation didnt provide me enough information .Could you please advise.


One approach:
You can create a “format service” which lets you convert the values but also “validate” the values/contents. It has to meet the Specification Reference: pub.flatFile:Formatservice.
In this service you can raise an error if the value does not match what you want, by setting the “meetsFormat” value to “false”.

Then you assign it to the Field in your schema.

Don’t forget to set the “validate” parameter of “pub.flatFile:convertToValues” to true.

Pros: Most of the definitions of the values are stored in the schema, and you have just to convert/validate contents once
Cons: The definitions of the values are a little bit “hidden”