Creating SQL scrapbook pages

You can use the SQL editor to create SQL statements in SQL scrapbook pages.

An SQL scrapbook page can contain one or more SQL statements. Each statement ends with a statement terminator. You can change the statement terminator in any SQL scrapbook page. The statement terminator applies to all of the SQL statements in a given scrapbook page.

You can create an SQL scrapbook page by using one of the following approaches:
  • The File menu
  • A project
  • The Database Explorer toolbar
  • A database
Prerequisites:
  • Create the project in which to store the SQL scrapbook page.
  • To create an SQL scrapbook page by using the Database Explorer toolbar or a database, create the database connection.

To create an SQL scrapbook page:

  1. Open the New SQL Scrapbook Page wizard.
    By using the File menu
    1. Click File > New > Other.
    2. In the New wizard, expand the Data node, click SQL Scrapbook Page, and then click Next.
    By using a project
    1. In a perspective other than the Data perspective, right-click the project folder, and then click New > Other on the pop-up menu.
    2. In the New wizard, expand the Data node, click SQL Scrapbook Page, and then click Next.
    By using the Database Explorer toolbar
    1. In the Database Explorer view of the Data perspective, click the Open SQL Scrapbook toolbar button.
    2. In the Connection Selection window, select the database connection, and then click OK.
    By using a database
    1. In the Database Explorer view of the Data perspective, expand the database connection.
    2. Right-click the database, and then click Open SQL Scrapbook on the pop-up menu.
  2. Complete the New SQL Scrapbook Page wizard, and then click Finish. The SQL scrapbook page is added to the project that you selected in the wizard and opens in the SQL editor.
  3. Specify one or more SQL statements in the SQL editor.
  4. Optional: If you want to use content assist and a No connection message is displayed in the status bar, connect to a database.
  5. Optional: Run the SQL statements in the SQL scrapbook page. If you run an INSERT, UPDATE, or DELETE statement, you can modify the database.
  6. Save the SQL scrapbook page.
Related tasks
Modifying SQL scrapbook pages
Running SQL statements in SQL scrapbook pages
Related information
SQL editor
Changing the SQL statement terminator
Using database connections in the SQL editor

Feedback