Common Coding Environment Features

From DBArtisan
Jump to: navigation, search

Go Up to Coding Environments/Editors

The following features are avaiable in all coding environments/editors:

Working with Comments

You can comment and uncomment blocks of code using the commenting scheme appropriate to the DBMS platform you are using.

To comment out code

  1. Select the block of code you want to comment out and then select Edit > Comment Out.

To uncomment code

  1. Select a complete block of commented code or a single line of the block and then select Edit > Undo Comment Out.

Working with Coding Environment Bookmarks

Bookmarks are valuable navigation aids for jumping from one portion of a script to another. You can add bookmarks in important areas of your scripts, then jump back and forth between bookmarks. A blue dot is inserted in the gutter next to lines that you bookmark.

at16fea1.jpg

To set a bookmark on a line or clear an existing bookmark from a line

  1. In the Editor window, position the pointer in front of the line and then select Edit > Toggle Bookmark.

To move the cursor back and forth among bookmarked lines

  1. Select Edit > Next Bookmark or Edit > Previous Bookmark.

To clear all bookmarks

  1. Select Edit > Clear Bookmark.

GoTo Line x

The Goto dialog lets you move to a specific line or column in your script.

To complete the Goto dialog, do the following:

  1. On the Edit menu, select Goto. The Go To dialog opens.
  2. In Line Number, type or select the target line number.
  3. Click OK.
    The cursor moves to the target line.

Using the Token Matching Capability

When you are working with a large script with multiple levels of embedded steps, compare left and right parentheses, curly braces, square brackets and BEGIN/END pairs to make sure that you have delimited your code properly.

To find matching tokens

  1. Position the insertion pointer just to the left of the first token in a token pair you want to locate.
  2. Click the Match Token button.
at172059.jpg
The pointer jumps to the next available token.