tFileInputJSON Standard properties
These properties are used to configure tFileInputJSON running in the Standard Job framework.
The Standard tFileInputJSON component belongs to the Internet and the File families.
The component in this framework is available in all Talend products.
Basic settings
Property Type |
Either Built-In or Repository. |
|
Built-In: No property data stored centrally. |
|
Repository: Select the repository file where the properties are stored. |
Schema and Edit schema |
A schema is a row description. It defines the number of fields (columns) to be processed and passed on to the next component. When you create a Spark Job, avoid the reserved word line when naming the fields.
Click Edit schema to make changes to the schema. If you make changes, the schema automatically becomes built-in.
|
Read By |
Select a way of extracting JSON data in the file.
|
Use Url |
Select this check box to retrieve data directly from the Web. |
URL |
Enter the URL path from which you will retrieve data. This field is available only when the Use Url check box is selected. |
Filename |
Specify the file from which you will retrieve data. This field is not visible if the Use Url check box is selected. Information noteWarning: Use absolute path (instead of relative path) for
this field to avoid possible errors.
|
Loop Jsonpath query |
Enter the JSONPath or XPath of the node on which the loop is based. Note if you have selected Xpath from the Read by drop-down list, the Loop Xpath query field is displayed instead. |
Mapping |
Complete this table to map the columns defined in the schema to the corresponding JSON nodes.
|
Die on error |
Select this check box to stop the execution of the Job when an error occurs. Clear the check box to skip the row on error and complete the process for error-free rows. If needed, you can collect the rows on error using a Row > Reject link. |
Advanced settings
JDK version |
Select the JDK version to be used. Note that a Standalone Nashorn JAR will be imported if you select JDK 11 and above. For JDK 8 to 11, Nashorn dependency is built in the JDK. This option is available when you select JsonPath without loop from the Read By drop-down list in the Basic settings view. Information noteNote:
|
Advanced separator (for numbers) |
Select this check box to change the separator used for numbers. By default, the thousands separator is a comma (,) and the decimal separator is a period (.). Thousands separator: define separators for thousands. Decimal separator: define separators for decimals. |
Use the loop node as root |
Select this check box to use the loop node as the root for querying the file. The loop node is set in the Loop Json query text frame in the Basic Settings view. If this option is checked, only the child elements of the loop node are available for querying; otherwise, both the parent elements and the child elements of the loop node can be queried. You can specify a parent element through JSON path syntax. This check box is available only when JsonPath is selected in the Read By drop-down list of the Basic settings view. |
Validate date |
Select this check box to check the date format strictly against the input schema. This check box is available only if the Read By XPath check box is selected. |
Encoding |
Select the encoding type from the list or select Custom and define it manually. This field is compulsory for DB data handling. |
Include the Nashorn library |
Select this option to include the Nashorn library. This option is necessary if you are using JDK 15 or a higher version. This option is available when JsonPath without loop is selected from the Read By drop-down list in the Basic settings view. |
tStatCatcher Statistics |
Select this check box to gather the Job processing metadata at a Job level as well as at each component level. |
Global Variables
Global Variables |
NB_LINE: the number of rows processed. This is an After variable and it returns an integer. ERROR_MESSAGE: the error message generated by the component when an error occurs. This is an After variable and it returns a string. This variable functions only if the Die on error check box is cleared, if the component has this check box. A Flow variable functions during the execution of a component while an After variable functions after the execution of the component. To fill up a field or expression with a variable, press Ctrl+Space to access the variable list and choose the variable to use from it. For more information about variables, see Using contexts and variables. |
Usage
Usage rule |
This component is a start component of a Job and always needs an output link. |