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 8871089
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T17:53:40+00:00 2026-06-14T17:53:40+00:00

I am trying to execute this script in Oracle 11g and getting the following

  • 0

I am trying to execute this script in Oracle 11g and getting the following error, I dont know where I am missing the paranthesis or what is the mistake kindly help me figure this out.

Script:

CREATE TABLE User_Role ( 
  user_role_id INT  NOT NULL  , 
  Users_user_id INT  FOREIGN KEY REFERENCES Users(user_id), 
  User_Types_user_type VARCHAR(20) FOREIGN KEY REFERENCES User_Types(user_type),  
  PRIMARY KEY(user_role_id) 
)

Error:

ORA-00907: missing right parenthesi

  • 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-06-14T17:53:41+00:00Added an answer on June 14, 2026 at 5:53 pm

    Delete FOREIGN KEY clause. Rewrite your CREATE TABLE statement as follows:

    CREATE TABLE User_Role ( 
          user_role_id         INT  NOT NULL  , 
          Users_user_id        INT  REFERENCES Users(user_id), 
          User_Types_user_type VARCHAR(20) REFERENCES User_Types(user_type),  
          PRIMARY KEY(user_role_id) 
        )
    

    In this case constraint names will be generated by Oracle. If you want to give them more meaningful names you could write your create table statement as follows:

      CREATE TABLE User_Role1 ( 
          user_role_id         INT  NOT NULL  , 
          Users_user_id        INT  , 
          User_Types_user_type VARCHAR(20) ,  
          constraint PK_YourTable PRIMARY KEY(user_role_id), 
          constraint FK_Table_1 foreign key(Users_user_id) REFERENCES Users(user_id),
          constraint FK_Table_2 foreign key(User_Types_user_type) REFERENCES User_Types(user_type)
        )
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to execute this script through JDBC (it's SQL Server): DECLARE @var VARCHAR(10)
I am trying to create a flashing arrow. However when I execute this script
I am trying to execute this simple script in php: $ch = curl_init(); curl_setopt($ch,
I'm trying to use the sql-maven-plugin to execute a PL/SQL script on an Oracle
I am a novice bash script user. I am trying to execute this postgresql
I am trying to execute this but cant see any result: <script> function init()
I'm trying to execute this command in in a bash script find /var/log/apache2/access*.gz -type
I was trying to execute this code through gcc compiler: #include <stdio.h> int main()
I'm trying to execute this: $ mysql --user=XXX --password=XXX --batch --skip-column-names \ -e SELECT
I'm trying to execute this code (this is a minimal sample in order to

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.