Results 1 to 5 of 5
  1. #1
    Join Date
    Oct 2010
    Posts
    2

    Unanswered: ORA-00907: missing right parenthesis

    I am trying to run the following query and keep getting a parenthesis error:

    SELECT
    l.libname
    FROM
    library l
    WHERE not exists (
    (select b.booknum from book b)
    except
    (select c.booknum from copy c where c.libnum = l.libnum));

    Any ideas what I am missing? I have tried to run this and several queries like it and keep getting this error.

  2. #2
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    On the surface I question the validity/correctness of "EXCEPT".
    Can you post URL showing it is valid?
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  3. #3
    Join Date
    Oct 2010
    Posts
    2
    Click image for larger version. 

Name:	IMG_0001.jpg 
Views:	48 
Size:	1.26 MB 
ID:	11268

    Please see the attachment outlining how the except can be used.

  4. #4
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    forgive me but I could see no detail.

    post functioning test case & SQL including functioning "EXCEPT"
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  5. #5
    Join Date
    Nov 2003
    Posts
    2,935
    Provided Answers: 12
    Quote Originally Posted by Andrew022 View Post
    Any ideas what I am missing? I have tried to run this and several queries like it and keep getting this error.
    Oracle does not use the ANSI standard EXCEPT
    In Oracle the equivalent is MINUS.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •