Skip to Main Content

Introduction

Use this site to teach about SQL and PL/SQL. Your students are given access to a new schema within an Oracle database each time they access Live SQL. As they run SQL and PL/SQL, each statement in the session is recorded and the last 10 sessions are stored for use. Any session can be saved permanently and saved scripts can be replayed, annotated, edited, shared and downloaded.

You can review homework and quizzes by having students save a script with the visibility set to Publicly Shareable and providing you the resulting URL. This enables you to see it but the work is not indexed and discoverable via the Live SQL search engine. Please do not instruct your students to submit assignments to be published - they will be declined.

Instructors can create tutorials that can be accessed via a dedicated url (as with Publicly Shareable scripts, these are only accessible to someone with the url and not indexed within the application). This feature allows you to include extensive explanations and code snippets for use by your class.

Live SQL does not allow all SQL and PL/SQL statement to be executed. In general, anything related to database administration or requiring access to another schema is not allowed. For more information on the lockdown in place, view the details on the Help page.

Capabilities

  • SQL Worksheet to run one or more SQL commands
  • Exclusive access to your own database (schema)
  • No access to other's work
  • Publicly share your work with others
  • Leverage numerous built-in datasets
  • Thousands of available scripts and tutorials
  • Ability to create custom tutorials
  • No cost, globally accessible

Saving Sessions as Scripts

Because access to an Oracle database schema is only for a limited period of time, work will need to be saved to be permanently available (the last 10 sessions are always available). Click Save within SQL Worksheet or Save Session within the My Scripts tab to save a session as a script. Within My Scripts, click on a specific script to edit, rerun or download. To share with others, first save the session as a script. During the save process, the visibility of the script is set (by default, scripts are private). To have students share their work, they should set the visibility to 'Publicly Shareable', which then provides a URL used to give someone else read access.

Editing SQL

Your students can view and edit their session by clicking the Session button from within the SQL Worksheet tab or the My Session tab. Each statement executed will be displayed and each will contain an edit link. While editing, they can add annotations which will display as comments. Once edited, sessions can be re-run. This will remove all existing database objects, clear out the session history, reset the NLS settings and re-run the edited SQL statements. Once perfected, the session an then be saved as a script.

To edit a script, students would click on the My Scripts tab and click the script to edit. This allows students to clean up their work to only share the statements they want before changing the visibility to Publicly Shareable and sharing with you for review.

Available Datasets

Oracle Live SQL provides several datasets for use. These include:
  • Human Resources (HR) - Oracle's HR sample schema.
  • Sales History (SH) - Oracle's SH sample schema (except SH.SALES_TRANSACTIONS_EXT).
  • EMP and DEPT (SCOTT) - Oracle's SCOTT schema (containing the commonly referenced EMP and DEPT tables).
  • World Data (WORLD) - Contains a WORLD_POPULATION table populated with data from 1960-2012.
  • Analytic Views (AV) - Used by the Analytic Views Hands-On Introduction.
  • Olympic Data (OLYM) - Summer Olympic medal winners from 1896 - 2008. Curated by Simon Rogers (the Guardian) and released as open data; Source: IOC.
  • Order Entry (OE) - Oracle's OE sample schema.
  • Academic (AD) - Contains course, department, faculty, etc. objects.
Datasets do not allow for data manipulation but can be viewed and referenced by prefacing the object name by the owning schema - e.g. "select * from SCOTT.EMP". This allows your students to use objects without needing to create them locally.

Available Tutorials

Tables, Columns and Modeling

  • Tables - Learn about the types of table available in Oracle Database, their uses, and how to use create table.
    Start this Tutorial

  • Columns and Data Types - When defining columns in a table, you need to choose a data type for them. This class you about the common SQL data types and their uses.
    Start this Tutorial

  • Data Modeling - Deciding where to store what is one of the fundamental decisions you make when building a database. This class gives an overview of the things you need to consider when designing your tables.
    Start this Tutorial

Basics of SQL queries: select, joins and group by

  • Select and Where - Learn how to use a select statement to get you rows from your database. And filter these data using a where clause.
    Start this Tutorial

  • Joins - Teaches you about the different types SQL join: inner, left and right outer, full, and cross.
    Start this Tutorial

  • Aggregates and Group By - Covers how you can summarize your data using aggregate functions and group by.
    Start this Tutorial

Legal Notices

Copyright Notice
Copyright © 2015, 2025, Oracle and/or its affiliates. All rights reserved.

License Restrictions Warranty/Consequential Damages Disclaimer

This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited.

Warranty Disclaimer

The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing.

Restricted Rights Notice

If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, then the following notice is applicable:

U.S. GOVERNMENT END USERS: Oracle programs, including any operating system, integrated software, any programs installed on the hardware, and/or documentation, delivered to U.S. Government end users are "commercial computer software" pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, use, duplication, disclosure, modification, and adaptation of the programs, including any operating system, integrated software, any programs installed on the hardware, and/or documentation, shall be subject to license terms and license restrictions applicable to the programs. No other rights are granted to the U.S. Government.

Hazardous Applications Notice

This software or hardware is developed for general use in a variety of information management applications. It is not developed or intended for use in any inherently dangerous applications, including applications that may create a risk of personal injury. If you use this software or hardware in dangerous applications, then you shall be responsible to take all appropriate fail-safe, backup, redundancy, and other measures to ensure its safe use. Oracle Corporation and its affiliates disclaim any liability for any damages caused by use of this software or hardware in dangerous applications.

Trademark Notice

Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.

Third-Party Content, Products, and Services Disclaimer

This software or hardware and documentation may provide access to or information about content, products, and services from third parties. Oracle Corporation and its affiliates are not responsible for and expressly disclaim all warranties of any kind with respect to third-party content, products, and services unless otherwise set forth in an applicable agreement between you and Oracle. Oracle Corporation and its affiliates will not be responsible for any loss, costs, or damages incurred due to your access to or use of third-party content, products, or services, except as set forth in an applicable agreement between you and Oracle.