|
Navigation: Property Pages > Common Property Pages > SQL Property Page |
![]() ![]()
|
The SQL Property Page is used to display the SQL that will be generated to the database. The SQL is created by evaluating a VB Script. See VB Scripts for more details.

SQL Property Page with the Run Script button selected

SQL Property Page with the Edit Script selected
Script Type
An object can have many different kinds of Scripts. i.e. a Create Script, a Drop Script, and Alter Script, a Pre Script (to be evaluated and generated before the Create Script), a Post Script (to be evaluated and generated after the Create Script), etc... This control allows you to select which script property you want to view or edit.
Toolbar
Run Script - evaluates the specified script type and displays the results.
Edit Script - lets you view and edit the VB script source code that is evaluated
Gutter Numbers
Cut, Copy, Paste
Find, Replace
Undo, Redo
SQL Execution Toolbar
Run - execute the SQL commands. If there isn't an active database connection, ModelRight will prompt you to login first.
Pause - pause the execution of the SQL commands.
Step Next - execute the next SQL command only.
Restart - restart executing the SQL commands - starting at the top.
Set Execution Line - set the execution point to the line where the caret is currently placed in the edit control. The
symbol is displayed in the gutter to the left of the SQL edit control to show the next command that will be executed. You can set the execution line to any line in the control simply by first clicking on the text of the line, and then selecting this button.
Toggle Breakpoint - Click in the edit control on the line that you want to set a breakpoint on and then click this button. A breakpoint will cause execution to pause when it gets to that line. The
symbol is displayed in the gutter to show where breakpoints are currently set.
- scroll to the next breakpoint
- scroll to the previous breakpoint
- remove all breakpoints
If you right-click in the SQL commands editor, the following menu will appear. You can Toggle Breakpoints, Set Execution Start, and Start Execution on the line you clicked on:

Apply To All
If you make changes to the VB Script, ModelRight creates a local value for the given script property. If you then decide that you want to use this VB Script for all objects (of the given type in the model), click the "Apply To All" button. This will removed the local value and set it on the corresponding Script object in the Script Explorer.This button becomes enabled only if you have changed the selected script property.
Default Schema Gen Options
The schema generation options affect the SQL that is generated. Click this link to go to the Default Schema Gen Options object to change the selected options. Just click the Navigate Back toolbar button
to get back to this property page to see the results.
See also:
Page url: http://www.modelright.com