Convert Long to Varchar2??
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 3 of 3

Thread: Convert Long to Varchar2??

  1. #1
    Join Date
    Apr 2002
    Posts
    61

    Convert Long to Varchar2??

    Hi,

    I have a column (name: error_msg) with LONG datatype. When I do instr on this column, I get an error stating that 'ORA-00932: inconsistent datatypes'. The following is my select statement.

    select instr(error_msg,'DATE_SIGNED' ) from ABC;

    I am guessing that I need to convert LONG datatype column to varchar2 to do instr. How do I convert LONG to VARCHAR2.

    Please advise.

    Thanks,
    Ramesh

  2. #2
    Join Date
    Nov 2000
    Location
    Pittsburgh, PA
    Posts
    3,999
    Have you tried INSTR(SUBSTR(error_msg, 2000), 'DATE_SIGNED' )?

  3. #3
    Join Date
    Apr 2002
    Posts
    61

    same error

    When I tried select INSTR(SUBSTR(error_msg, 2000), 'DATE_SIGNED' ) from ABC, I got the same error (i.e, inconsistent datatypes).
    Thanks,
    Ramesh

Posting Permissions

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



Click Here to Expand Forum to Full Width