Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 716867
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T05:20:51+00:00 2026-05-14T05:20:51+00:00

For my application that uses an Oracle 8 DB, I am providing an SQL

  • 0

For my application that uses an Oracle 8 DB, I am providing an SQL script to setup stuff like triggers, sequences etc., which can be copied and pasted into SQL*Plus. I would like the script to not stop with an error if a sequence that I am trying to create already exists. For a Trigger this can easily be done using “create or replace trigger …”, but for a sequence this does not work. I also tried “”if not exists mysequence then create sequence …” but it did not too. Is there some alternative?

Alternatively, if this is not possible, is there a way to do a “drop sequence mysequence” without SQL*Plus aborting the script if mysequence does not exist?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T05:20:52+00:00Added an answer on May 14, 2026 at 5:20 am

    If you’re sure the script will always run under SQL*Plus, you can bracket the CREATE SEQUENCE statements with a directive to continue on error:

    WHENEVER SQLERROR CONTINUE
    -- create sequences here, ignoring errors
    WHENEVER SQLERROR EXIT SQL.SQLCODE
    

    Be aware if there are other errors (permission problems, syntax failures, etc.) in the create sequence statements they will be ignored

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have built an application that uses SQL Express 2005 and I want to
I am working on an application that uses Oracle's built in authentication mechanisms to
I'm building a web application that uses Oracle Database 10g as the database backend.
I'm in charge of a Perl application that uses DBD::Oracle compiled against a 9.2.0.8
I developed an application that uses Delphi 7, ADO and ORACLE, the provider I
Can anyone share a link to sample (ASP).Net code that uses the new Oracle
I have an application that uses NHibernate as its ORM and sometimes it experiences
I have a Windows application that uses a .NET PropertyGrid control. Is it possible
We distribute an application that uses an MS Access .mdb file. Somebody has noticed
I work on an application that uses DCOM to communicate between what are essentially

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.