Working with SQL scrapbook pages

In addition to SQL statements that you create through the New SQL Statement wizard, you can create SQL scrapbook pages in the SQL editor. An SQL scrapbook page can contain one or more SQL statements.

You can work with an SQL scrapbook page in many of the same ways that you work with an SQL statement created through the New SQL Statement wizard. However, there are a few limitations. The following table summarizes the comparison of an SQL scrapbook page to an SQL statement that is created through the New SQL Statement wizard. For more detailed information, refer to the topic that describes the specific functionality.

Table 1. Comparison of SQL scrapbook page to SQL statement created through wizard
Function SQL scrapbook page SQL statement created through wizard
Available tools SQL editor SQL builder and SQL editor
SQL statement types Data Definition Language (DDL) and Data Manipulation Language (DML)
  • SQL builder: DML only
  • SQL editor: with template, DML only; without template, both DML and DDL
Create file
  • Any development perspective: File menu
  • Data perspective, Database Explorer view : toolbar button and pop-up menu
  • Any development perspective: File menu
  • Data perspective, Data Project Explorer view: pop-up menus in data projects
  • Data perspective, Database Explorer view: toolbar button and pop-up menus
Statement template provided No Yes, for DML statements
Multiple SQL statements in one file Yes
  • SQL builder: no
  • SQL editor: yes, but DML template provided for first statement only
Format of saved file XML Raw SQL
Extension of saved file .sqlpage .sql
Edit file SQL editor: any development perspective, except Data
  • SQL builder: Data perspective only
  • SQL editor: any development perspective
  • other text editors: any development perspective, except Data
Run file From SQL editor
  • From SQL builder
  • From SQL editor
  • From Data Project Explorer view of Data perspective
Host variables in SQL statement No
  • Run from SQL builder: yes
  • Run from SQL editor: no
  • Run from Data Project Explorer view of Data perspective: yes
Import SQL statement into stored procedure or user-defined function No Yes

Feedback