Modifying ESQL for a node

If you want to change the customization of a node that requires ESQL (Compute, Database, or Filter), you can modify the ESQL statements within the module that you created for that node.

Before you start

To complete this task, you must have completed the following task:

To modify ESQL code:

  1. Switch to the Broker Application Development perspective.
  2. In the Navigator view, select the message flow that you want to work with and double-click it. The message flow is opened in the editor view.
  3. Right-click the node corresponding to the ESQL module that you want to modify and click Open ESQL. The ESQL file is opened in the editor view. The module for this node is highlighted.
  4. Make the changes that you want in the module, by entering new statements (remember that you can use Content Assist, available from the Edit menu or, on some systems, by pressing Ctrl+Space), changing existing statements by overtyping, or deleting statements using the Delete or backspace keys. Note that, to get Content Assist to work with message references, you must set up a project reference from the project containing the ESQL to the project containing the message set. For information about setting up a project reference, see Project references.
  5. You can change the name of the module that you are working with, by over-typing the current name with the new one. Remember that, if you do that, you must also change the node property ESQL Module to reflect the new name to ensure that the correct ESQL code is deployed with the node.
  6. When you have finished working with this module, you can close the ESQL file. Save the file before you close it to retain all your changes and validate your ESQL.

If you prefer, you can open the ESQL file directly by double-clicking it in the Navigator view. You can select the module that you want to work with from the Outline view.

The editor provides functions that you can use to help you modify your ESQL code. These functions are described in ESQL editor.

You can also modify the ESQL source by selecting Source > Format. This option formats all selected lines of code (unless only partially selected, when they are ignored), or, if no lines are selected, formats the entire file (correcting alignments and indentation).

Adding comments to ESQL

You can add comments to and remove comments from your ESQL code:

  1. To change an existing line of code into a comment line, click Source > Comment.
  2. To change a comment line to a code line, click Source > Uncomment.
  3. To create a new comment line, press Enter to create a new line and either type the comment identifier -- or click Source > Comment. You can enter any text after the identifier: everything you type is ignored by the ESQL editor.