ORA-01480: trailing null missing from STR bind value Problem

Source: Internet
Author: User


ORA-01480: trailing null missing from STR bind value problem [problem] Using PL/SQL to change data, the field in the table is varchar2 (4000 ), when you modify a data in a table, use for update directly to make a data change. The length of the data is more than 2000, but the ORA-01480 is reported at the time of submission: trailing null missing from STR bind value error [Analysis] There are two possible causes: 1. the pl/SQL tool causes this problem because toad does not. Ii. Variable Length in OCI. This error indicates that the string is truncated in the middle and cannot be correctly parsed. www.2cto.com [solution] 1. the TOAD tool can be used to directly change the data. This problem does not occur when the data is submitted. You can solve this problem directly, but simply install a toad tool for this problem, especially those who are used to pl/SQL tools are not a good method. 2. if you do not use for update, the insert or update statement can solve this problem, but there are a lot of quotation marks or percent signs in the middle. It is very troublesome to solve. You can add escape characters one by one, very difficult. There is also a small way to solve this problem. Replace the single quotation marks or percent signs in the original string with other symbols, such as #, $, and so on. After inserting data into the database, run a simple update replace statement to quickly solve this problem.
 

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.