Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: ORA-01401: inserted value too large for column

RE: ORA-01401: inserted value too large for column

From: Jacques Kilchoer <Jacques.Kilchoer_at_quest.com>
Date: Thu, 16 Oct 2003 15:29:25 -0800
Message-ID: <F001.005D36AE.20031016152925@fatcity.com>


That's funny. When I tried it on Oracle 9.0.1.1.0 on SunOS there was no error. When I tried it on Oracle 9.2.0.3.0 on SunOS the value assigned to po_out was an X followed by two (2) spaces.

> -----Original Message-----
> Post, Ethan
>
> Seeing this on AIX 5.1 64 bit Oracle 9.2.0.1.0 with char
> datatypes. Anyone
> aware of this issue?
>
> CREATE TABLE CHAR_TEST
> (
> CHAR1 CHAR(1)
> )
>
>
> --------------------------------------------------------------
> --------------
> ------------------------------
>
> CREATE OR REPLACE PROCEDURE TEST_CHAR (
> po_out OUT CHAR_TEST.CHAR1%TYPE -- this column is defined
> as CHAR(1)
> )
> IS
> BEGIN
>
> po_out := 'X';
>
> -- The value assigned to po_out (in Oracle 9i instance) is
> an 'X' followed
> by 199 spaces.
> -- The value assigned to po_out (in Oracle 8i instance) is
> an 'X', no
> spaces.
> dbms_output.put_line('[BEGIN]-->' || po_out || '<--[END]');
>
> -- In Oracle 9i, the following will cause the exception: "ORA-01401:
> inserted value too large for column"
> INSERT INTO CHAR_TEST (CHAR1)
> VALUES (po_out);
>
> EXCEPTION WHEN OTHERS
> THEN
> dbms_output.put_line('Error: ' || SQLERRM);
> END;

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Jacques Kilchoer
  INET: Jacques.Kilchoer_at_quest.com

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Thu Oct 16 2003 - 18:29:25 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US