Results 1 to 7 of 7
  1. #1
    Join Date
    Feb 2008
    Posts
    26

    Unanswered: Comments don't pass with Oracle OleDb Provider

    Hello everybody !

    I work on Windows platform, so I use ADO components to connect to an Oracle 9i database.
    I execute some SQL queries by the Open() ADO functions but there are errors when the queries content comments (--)
    I need these comments, I haven't to remove them

    Have you already met a situation like that ? I try with the Microsoft Oracle Provider, it passes but this provider is incompatible with many things (blob, timestamp, etc.), it's why I must use Oracle one

    What is the solution ? (thanks in advance)

  2. #2
    Join Date
    Feb 2008
    Posts
    26
    Have someone an idea to solve it ?

  3. #3
    Join Date
    Jun 2003
    Location
    West Palm Beach, FL
    Posts
    2,713

    Talking

    Why do you need the embeded comments? Move them outside the query.
    .
    The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb

  4. #4
    Join Date
    Feb 2008
    Posts
    26
    I explain the situation: the queries failed when there is a comment before or inside the queries (comment with 2 dashes) !!! No problem when the comment is after, normal because no instruction to execute !

    Why do you need the embeded comments? Move them outside the query.
    Read up !!

    The solution that I found out is the use of /**/, it works with Oracle provider but i wonder why the created procedures are in one line when I watch in OEM ???, one line for a many lines of one procedure, it's so worst

  5. #5
    Join Date
    Jun 2004
    Location
    Liverpool, NY USA
    Posts
    2,509
    -- means that EVERY thing in the following line is a comment, you can't terminate it. Using /* and */ you can define a block of comments.
    Bill
    You do not need a parachute to skydive. You only need a parachute to skydive twice.

  6. #6
    Join Date
    Feb 2008
    Posts
    26
    Yes I know beilstwh but when I create the procedure, my script is multiline but when it is created, i look at OEM, it is in one line !!! Strange !!!

    So, it is why /* and */ is the comment type to use !!

  7. #7
    Join Date
    Feb 2008
    Posts
    26
    What are your opinions ?
    Doesn't Oracle Olebd provider support CR LF for next line ?

Posting Permissions

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