# tJavaRow Standard properties

These properties are used to configure tJavaRow running in the Standard Job framework.

The Standard tJavaRow component belongs to the Custom Code family.

The component in this framework is available in all Talend products.

## Basic settings

| Properties | Description |
| --- | --- |
| Schema and Edit<br>Schema | <ul> <li> <p>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 <kbd>line</kbd> when naming the            fields.</p> <p>This component offers the advantage of the                  dynamic schema feature. This allows you to retrieve unknown columns from source                  files or to copy batches of columns from a source without mapping each column                  individually. For further information about dynamic schemas, see <a href="https://help.qlik.com/talend/r/en-US/8.0/studio-user-guide/dynamic-schema" target="_blank">Dynamic schema</a>.</p> <p>This            dynamic schema feature is designed for the purpose of retrieving unknown columns of a            table and is recommended to be used for this purpose only; it is not recommended for the            use of creating tables.</p> </li> <li> <p> <span>Built-In</span>: You create and store the schema locally for this component                only.</p> </li> <li> <p> <span>Repository</span>: You have already created the schema and stored it in the                Repository. You can reuse it in various projects and Job designs.</p> <p>When the schema to be reused has default values that are            integers or functions, ensure that these default values are not enclosed within            quotation marks. If they are, you must remove the quotation marks manually.</p> <p>For more information, see <a href="https://help.qlik.com/talend/r/en-US/8.0/studio-user-guide/retrieving-table-schemas?tocId=_C1~eFOlN~GM_JR2qkBYZg" target="_blank">Retrieving table schemas</a>.</p> </li> <li> <p>Click <span>Edit        schema</span> to make changes to the schema. If the current schema is of the <span>Repository</span> type, three options are available:</p> <ul> <li> <p> <span>View schema</span>: choose this                option to view the schema only.</p> </li> <li> <p> <span>Change to built-in property</span>:                choose this option to change the schema to <span>Built-in</span> for local changes.</p> </li> <li> <p> <span>Update repository connection</span>:                choose this option to change the schema stored in the repository and decide whether                to propagate the changes to all the Jobs upon completion.</p> <p>If you just want to                propagate the changes to the current Job, you can select <span>No</span> upon completion and choose this schema metadata                again in the <span>Repository Content</span>                window.</p> </li> </ul> <p>Click <span>Sync        columns</span> to retrieve the schema from the previous component connected in the      Job.</p> </li> </ul> |
| Generate code | Click this button to automatically generate the code in the Code field to map the columns of the input schema with those of the output<br>schema. This generation does not change anything in your schema.<br><br>The principle of this mapping is to relate the columns that have the same column name.<br>Then you can adapt the generated code depending on the actual map you need. |
| Code | Enter the Java code to be applied to each line of the data<br>flow. |

## Advanced settings

| Properties | Description |
| --- | --- |
| Import | Enter the Java code to import, if necessary, external libraries<br>used in the Code field of the Basic settings view. |
| tStatCatcher Statistics | Select this check box to collect the log data at a component<br>level.. |

## Global Variables

| Variables | Description |
| --- | --- |
| Global Variables | NB\_LINE: the number<br>of rows read by an input component or transferred to an output component. This is an<br>After variable and it returns an integer.<br><br><br>ERROR\_MESSAGE: the error message generated by the<br>component when an error occurs. This is an After variable and it returns a string. This<br>variable functions only if the Die on error checkbox is<br>cleared, if the component has this checkbox.<br><br>A Flow variable functions during the execution of a component<br>while an After variable functions after the execution of the component.<br><br>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<br>it.<br><br>For more information about variables, see [Using contexts and variables](https://help.qlik.com/talend/r/en-US/8.0/studio-user-guide/contexts-and-variables).<br><br>To enter a global variable (for example *COUNT* of tFileRowCount) in the Code box, you need to type in the entire piece of code manually, that<br>is to say *((Integer)globalMap.get("tFileRowCount\_COUNT"))*. |

## Usage

| Usage guidance | Description |
| --- | --- |
| **Usage rule** | This component is used as an intermediary between two other<br>components. It must be linked to both an input and an output<br>component. |
| Function | tJavaRow allows you to enter<br>customized code which you can integrate in a Talend programme. With tJavaRow, you can enter the Java code to be<br>applied to each row of the flow. |
| Purpose | tJavaRow allows you to broaden the<br>functionality of<br>Talend<br>Jobs, using the<br>Java language. |
| Limitation | Knowledge of Java language is necessary. |