DBAsupport.com Forums - Powered by vBulletin
Results 1 to 6 of 6

Thread: ORA-01460

  1. #1
    Join Date
    Jul 2000
    Posts
    521
    I was trying to get a LONG column into a VARCHAR2(32767) column in PL/SQL block. Then while trying to use functions like SUBSTR, LENGTH on the varchar2 variable, I am getting this error. How to overcome this ?

    Ver : 8.0.6
    svk

  2. #2
    Join Date
    Oct 2000
    Location
    Saskatoon, SK, Canada
    Posts
    3,925
    Certainly it will be an error as the max size a varchar could hold is only 4000. In V8 I presume it to be of 2000 (not suer!)

    Sam
    Thanx
    Sam



    Life is a journey, not a destination!


  3. #3
    Join Date
    Jul 2000
    Posts
    521
    That is the limit for a VARCHAR2 "column". For a varchar2 "variable" in pl/sql block, 32767 is okay.
    svk

  4. #4
    Join Date
    Oct 2000
    Location
    Saskatoon, SK, Canada
    Posts
    3,925
    Yes 32K is the block limit for the varchar2. But in your case what happens is that when you pass the data to a SUBSTR or LENGTH function which would use the SELECT internally to get the results. Since the SELECT has a cap of 4000 on varchar2 datatype, it would fail and ends up coming out with the ORA-1460 error.


    Sam
    Thanx
    Sam



    Life is a journey, not a destination!


  5. #5
    Join Date
    Jul 2000
    Posts
    521
    How do I read the contents of a LONG column then ?
    svk

  6. #6
    Join Date
    Oct 2000
    Location
    Saskatoon, SK, Canada
    Posts
    3,925
    Thanx
    Sam



    Life is a journey, not a destination!


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