Templates allow you to enter predefined SQL code into your procedural object at the desired location. You can also enter predefined values for variables in the template so that all instances of the variable are updated at the same time when a change is made to any one instance.
To use templates in SQL Editor:
In the SQL Editor, position the cursor where you want to insert a template.
Open content assist by pressing the Eclipse content assist key sequence. The default is Ctrl+Space.
Templates appear in the options list along with other syntax proposals in content assist. Select and double-click the template you want to insert into SQL Editor. You can also navigate the content assist list using the Up or Down arrow key until you find the template.
Templates can contain variables, which act as placeholders for the dynamic part of a template pattern. The variable changes with every application of the template. When you insert a template into SQL Editor and the template pattern contains a variable, SQL Editor enters Template Edit mode. The first variable is underlined and selected. When you enter the variable value, all instances of the variable are updated simultaneously.
To use and navigate a template in Template Edit mode:
Enter values in the variable placeholders. All instances of the same variable are replaced by the value you enter.
Press Tab to move the cursor to the next unique variable. Press Shift+Tab to move the cursor backward to the previous unique variable. Enter values for all variable placeholders.
Exit Template Edit mode by pressing the Esc or Enter key when you have completed entering values for the variables.
Send your feedback on this help topic to Sybase Tech Pubs: pubs@sybase.com