Oracle must die with a strange ORA-06502 Error

Source: Internet
Author: User

As a skilled. Net coders and unskilled Oracle users, Oracle always gives me the feeling that this product is disgusting.

Although I have to admit that Oracle is a very good (an) Good (gui) product, it is always so disgusting. For example, the driver is the same as the driver, and the strange mistake encountered today.

The thing is this: when new information is added to the database, the system always reports a ORA-06502 when executing the following script:

Getmaterialinfo () dual

Description: getmaterialinfo is a function that returns varchar2. Well, it seems that there is a problem with the variable size in the function, so we can debug it decisively.

However, a miracle occurred when the following debugging statement was executed:

((;

Yes, nothing happened !!!! This is the normal end !!!!! A miracle happened because nothing happened. What can it be?

Okay, just skip it. Let's just draw a conclusion:

The returned string length exceeds 4000, and the default buffer size is 4000. Therefore, Oracle decisively reports an error (not understanding why the returned type is set to varchar2 (5000) you still need to tangle the return length ...... Please explain ?), Throw an error that cannot be guessed by the description of the error output.

Refer to Solution.

Finally, Oracle must die.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.