Oracle Tutorial

  • Home
  • Start Here
  • Basics
  • Advanced
    • Oracle View
    • Oracle Index
    • Oracle Synonym
    • Oracle Sequence
    • Oracle Administration
  • PL/SQL
  • Functions
    • Aggregate Functions
    • Analytic Functions
    • Comparison Functions
    • Date Functions
    • String Functions
  • API
    • Python Oracle
Home / Oracle Sequence / Oracle DROP SEQUENCE

Oracle DROP SEQUENCE

Summary: in this tutorial, you will learn how to use the Oracle DROP SEQUENCE statement to remove a sequence from the database.

Oracle DROP SEQUENCE overview

The DROP SEQUENCE statement allows you to remove a sequence from the database.

Here is the basic syntax of the DROP SEQUENCE statement:

DROP SEQUENCE schema_name.sequence_name;

In this syntax, specify the name of the sequence that you want to remove after the DROP SEQUENCE keywords.

If you don’t specify the schema to which the sequence belongs, Oracle will remove the sequence in your own schema.

The sequence that you remove must be in your own schema or you need to have the DROP ANY SEQUENCE system privilege to remove a sequence in any schema.

The DROP SEQUENCE statement is also useful in case you want to restart a sequence.

For example, if you have a sequence with the current value of 100 and you want to restart the sequence with a value of 50, then you can drop the sequence and re-create it with a START VALUE of 50.

Oracle DROP SEQUENCE example

This statement creates a new sequence called no_seq:

CREATE SEQUENCE no_seq;

To remove the no_seq from the database, you use the following statement:

DROP SEQUENCE no_seq;

In this tutorial, you have learned how to use the OracleDROP SEQUENCE statement to remove a sequence from the database.

  • Was this tutorial helpful?
  • YesNo
Previous Oracle ALTER SEQUENCE

Getting Started

  • What Is Oracle Database
  • Install Oracle Database Server
  • Download Oracle Sample Database
  • Create Oracle Sample Database
  • Connect To Oracle Database Server

Oracle Data Manipulation

  • SELECT
  • Oracle DUAL Table
  • ORDER BY
  • SELECT DISTINCT
  • WHERE
  • Table & Column Aliases
  • AND
  • OR
  • FETCH
  • BETWEEN
  • IN
  • LIKE
  • IS NULL
  • Joins
  • INNER JOIN
  • LEFT JOIN
  • RIGHT JOIN
  • FULL OUTER JOIN
  • CROSS JOIN
  • Self Join
  • GROUP BY
  • HAVING
  • UNION
  • INTERSECT
  • MINUS
  • GROUPING SETS
  • CUBE
  • ROLLUP
  • PIVOT
  • UNPIVOT
  • INSERT
  • INSERT INTO SELECT
  • INSERT ALL
  • UPDATE
  • DELETE
  • MERGE
  • Subquery
  • Correlated Subquery
  • EXISTS
  • NOT EXISTS
  • ANY
  • ALL

Oracle Data Types

  • Oracle Data Types
  • NUMBER
  • FLOAT
  • BINARY_FLOAT
  • CHAR
  • NCHAR
  • VARCHAR2
  • NVARCHAR2
  • DATE
  • INTERVAL
  • TIMESTAMP
  • TIMESTAMP WITH TIME ZONE

Oracle Data Definition

  • CREATE TABLE
  • Identity Column
  • ALTER TABLE
  • ALTER TABLE ADD Column
  • ALTER TABLE MODIFY Column
  • Drop Columns
  • DROP TABLE
  • TRUNCATE TABLE
  • RENAME Table
  • Oracle Virtual Column

Oracle Constraints

  • PRIMARY KEY
  • FOREIGN KEY
  • UNIQUE
  • CHECK
  • NOT NULL

Oracle Views

  • CREATE VIEW
  • DROP VIEW
  • Updatable Views
  • Inline Views
  • WITH CHECK OPTION

About Oracle Tutorial

OracleTututorial.com website provides Developers and Database Administrators with the updated Oracle tutorials, scripts, and tips.

Search

Recent Tutorials

  • Oracle Implicit Statement Results
  • Calling PL/SQL Stored Functions in Python
  • Calling PL/SQL Procedures in Python
  • Managing Transaction in Python
  • Deleting Data From Oracle Database in Python

Site Links

  • Oracle Books
  • About
  • Contact
  • Privacy Policy
  • Terms of Use

Copyright © 2021 Oracle Tutorial. All Rights Reserved.