Using the Command Editor
You use the command editor in SQL Commands to execute SQL commands within Oracle Application Express.
- Running a SQL Command
Enter the SQL command you want to run in the command editor and click Run. - About Transactions in SQL Commands
Transactional mode is a stateful transaction mode where you can, for example, perform an update, select data for review, andCOMMIT
orROLLBACK
changes. It is implemented usingDBMS_JOBS
. - Disabling Transactional SQL Commands
Check the Autocommit check box to disable transactional SQL commands. - Enabling Transactional SQL Commands
Uncheck the Autocommit check box to enable the transactional SQL commands. - About Unsupported SQL*Plus Commands
SQL Commands does not support SQL*Plus commands. - Terminating a Command
You can terminate a command in SQL Commands using a semicolon (;), a slash (/), or with nothing. - Using Bind Variables
Enter values for bind variables during command execution. - Using the Find Tables Button
Use the Find Tables button to view tables within the currently selected schema.
See Also:
Parent topic: Using SQL Commands
Running a SQL Command
Enter the SQL command you want to run in the command editor and click Run.
To execute a SQL Command:
Parent topic: Using the Command Editor
About Transactions in SQL Commands
Transactional mode is a stateful transaction mode where you can, for example, perform an update, select data for review, and COMMIT
or ROLLBACK
changes. It is implemented using DBMS_JOBS
.
Consider the following behavior in transactional mode:
-
Actions are not committed to the database until you enter an explicit
COMMIT
command. -
Exiting SQL Commands terminates and rolls back the current transaction.
-
A session timeout terminates and rolls back the current transaction.
Note that the Environment Setting,
SQL Commands Maximum Inactivity in minutes
, sets the time before an inactive session times out. The default timeout is 60 minutes. -
The CSV Export option is not available.
See Also:
"Configuring SQL Workshop"in Oracle Application Express Administration Guide
Parent topic: Using the Command Editor
Disabling Transactional SQL Commands
Check the Autocommit check box to disable transactional SQL commands.
To disable transactional SQL commands in SQL Commands, check the Autocommit check box. Attempting to use any transactional SQL commands such as COMMIT
or ROLLBACK
when transactional mode is disabled returns an error message.
Parent topic: Using the Command Editor
Enabling Transactional SQL Commands
Uncheck the Autocommit check box to enable the transactional SQL commands.
To enable transactional SQL commands, clear the Autocommit check box. Oracle Application Express verifies that the necessary system resources are available before entering the transactional mode. If resources are unavailable, an error message is displayed.
Parent topic: Using the Command Editor
About Unsupported SQL*Plus Commands
SQL Commands does not support SQL*Plus commands.
If you attempt to enter an SQL Command Line command such as SET ECHO
or DEFINE
in SQL Commands, an error message displays.
Parent topic: Using the Command Editor
Terminating a Command
You can terminate a command in SQL Commands using a semicolon (;), a slash (/), or with nothing.
Consider the following valid alternatives:
SELECT * from emp;
SELECT * from emp
/
SELECT * from emp
The first example demonstrates the use of a semicolon (;), the second example demonstrates using a slash (/), and the final example demonstrates a command with no termination.
Parent topic: Using the Command Editor
Using Bind Variables
Enter values for bind variables during command execution.
Bind variables are supported. You are prompted to enter values for bind variables during command execution. Bind variables are prefixed with a colon.
For example
SELECT * FROM emp WHERE deptno = :dept
Parent topic: Using the Command Editor
Using the Find Tables Button
Use the Find Tables button to view tables within the currently selected schema.
To view tables within the current schema:
Parent topic: Using the Command Editor