Skip to main content Skip to complementary content
Close announcements banner

Defining context variables from the Component view

About this task

The quickest way to create a single context variable is to use the F5 key from the Component view. The following example demonstrates how to create a context variable while configuring a file path for a component in a Job.

Procedure

  1. On the relevant Component view, place your cursor in the field you want to parameterize.
  2. Press F5 to display the New Context Parameter dialog box:
    New Context Parameter dialog box.
  3. Give a Name to this new variable, fill in the Comment field if needed, and choose the Type.
    Information noteNote: The variable name should follow some typing rules and should not contain any forbidden characters, such as space character.
  4. If you have not installed the 8.0 R2023-09 Talend Studio monthly update or a later one provided by Talend, select the Enable prompt check box to be displayed to confirm the use of this variable in the current Job execution (generally used for test purpose only), select the Prompt for value check box to display the prompt message and an editable value field at the execution time.
  5. If you filled in a value already in the corresponding properties field, this value is displayed in the Default value field. Else, type in the default value you want to use for one context.
  6. Click Finish to validate.
  7. Go to the Context view tab. Notice that the context variables tab lists the newly created variables.

Results

The newly created variables are listed in the Context view. The variable created this way is automatically stored in all existing context environments, but you can subsequently change the value independently in each context environment. For more information on how to create or edit a context environment, see Defining context environments.

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – let us know how we can improve!