Top Banner
1 The SQL* Family: SQL*Plus, SQL Developer and SQLcl Ami Aharonovich Oracle ACE & OCP [email protected]
20

The SQL* Family: SQL*Plus, SQL Developer and SQLcl

Jan 07, 2022

Download

Documents

dariahiddleston
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

1

The SQL* Family: SQL*Plus,

SQL Developer and SQLcl

Ami Aharonovich

Oracle ACE & OCP

[email protected]

Page 2: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

2

About Me

Oracle ACE

Oracle Certified Professional DBA (OCP)

Founder and CEO, Brillix-DBAces

President, Israel Oracle User Group

Ambassador, EMEA Oracle User Group Community

Oracle DBA consultant and instructor, specializing in Oracle database core technologies

Frequent speaker at Oracle Open World annual event and various user group conferences around the globe

Page 3: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

3

About Brillix

• We develop and manage data platforms and data security solutions

• We offer complete integrated end-to-end solutions based on best-

of-breed innovations in database, security and big data technologies

• We are committed to provide the highest quality of products and

services delivered by our world renown dedicated team of industry’s

top data experts

Page 4: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

4

Our Customers

Page 5: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

5

Page 6: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

6

Page 7: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

7

Agenda

• SQL*Plus

• SQL Developer

• SQLcl

• Live demo

Page 8: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

8

SQL*Plus

Page 9: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

9

SQL*Plus – History

• Oldest, most basic Oracle database command-line utility

• First version was called UFI (User Friendly Interface), until the

release of Oracle Database version 4

• Later it was changed to Advanced UFI and then to SQL*Plus

with the release of version 5

• SQL*Plusw – Windows “GUI” version

• iSQL*Plus – web based version

Page 10: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

10

SQL*Plus

• Automatically installed with every Oracle database version

• The first tool to be updated when syntax changes

• Very strong integration with other Oracle infrastructure tools

• Supports SQL statements, PL/SQL blocks, use of variables,

internal commands, prompt command, external commands

• Scripts are typically used for batch processes and maintenance

• Still getting new features added, even 12c R2 has a few…

Page 11: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

11

SQL*Plus Useful Commands

• COPY

• MARKUP HTML

• SPOOL APPEND

• LIST, CHANGE and RUN

• GLOGIN.SQL (script file)

• PROMPT (ACCEPT) and NEW_VALUE

• WHENEVER SQLERROR

• ERRORLOGGING (11g R1)

• EXITCOMMIT (11g R2)

Page 12: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

12

ERRORLOGGINGOracle 11g R1 (11.1)

• Enables error logging of SQL, PL/SQL and SQL*Plus errors

• Errors are written to a default table: SPERRORLOG:

– Username

– time of error

– script name (if applicable)

– user-defined identifier (to see errors from a specific session)

– ORA, PLS or SP2 error messages

– the statement that caused the error

– ROLLBACK issue: create a view and an instead of trigger

Page 13: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

13

SQL Developer

• Free, integrated development environment that simplifies the

development and management of Oracle database. It offers:

– Complete end-to-end development of your PL/SQL applications

– Worksheet for running queries and scripts

– DBA console for managing the database

– Reports interface

– Complete data modeling solution

– Migration platform, moving 3rd party databases to Oracle

Page 14: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

14

SQL Developer Useful FeaturesVersion 17.3.1, updated October 17th, 2017

• Grouping connections

• Export/import connections

• Multi-cursor editing

• Formatting the SQL code

• Editing and using snippets

• Creating reports (csv, xml, …)

• Database document and reports

• Import data wizard

• Real time SQL monitor

• Code templates

• Shortcut keys

• Schema compare

• SQL Data Modeler

• Monitor SQLs and sessions

• Instance viewer

• DBA tools (multitenant)

• Instance Viewer

• Copy database to Oracle cloud

Page 15: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

15

SQL Developer Useful Links

• SQL Developer:

http://www.oracle.com/technetwork/developer-tools/sql-developer/overview/index-097090.html

• SQL Developer Exchange:

https://apex.oracle.com/pls/apex/f?p=43135:1

• SQL Developer OTN Forum:

https://community.oracle.com/community/database/developer-tools/sql_developer

• SQL Developer Online Tutorials:

http://www.oracle.com/technetwork/developer-tools/sql-developer/obe-082749.html

Page 16: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

16

SQL Developer Command Line – SQLcl (17.3)version updated September 29th, 2017

• Free command line interface for Oracle database

• Execute SQL and PL/SQL either interactively or batch

• It is the “New SQL*Plus on Steroids”

• Provides: in-line editor, auto-complete, command history,

new commands (CTAS, DLL, REPEAT, ALIAS, and more…),

SQL*Plus support

• No installation required

• It is part of the SQL Developer suite

• Java based

Page 17: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

17

SQLcl Useful Commands

• Object Completion (Tab)

• HISTORY

• INFO, INFO+

• DDL

• ALIAS

• REPEAT

• CTAS

• LOAD

• SQLFORMAT (csv, html, xml, insert, loader…)

Page 18: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

18

SQLcl Keyboard Shortcuts

• Ctrl+W – top first line

• Ctrl+A – beginning of line

• Ctrl+E – end of line

• Ctrl+S – bottom of buffer

• Ctrl+R – run

• Ctrl+L – clear screen

Page 19: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

19

SQLcl Useful Links

SQL Developer Command Line SQLcl 17.3 Release Notes:

http://www.oracle.com/technetwork/developer-tools/sql-

developer/overview/sqlcl-relnotes-173-3939847.html

SQL Developer Command Line SQLcl Forums:

https://community.oracle.com/community/database/developer-

tools/sql_developer/sqlcl

Jeff Smith, SQL Developer Product Manager (@thatjeffsmith):

http://www.thatjeffsmith.com

Page 20: The SQL* Family: SQL*Plus, SQL Developer and SQLcl

20

The SQL* Family: SQL*Plus,

SQL Developer and SQLcl

Ami Aharonovich

Oracle ACE & OCP

[email protected]