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

Home -> Community -> Usenet -> c.d.o.server -> Which column caused ORA-01438?

Which column caused ORA-01438?

From: The Gooch <uhcnam_at_hotmail.com>
Date: 31 May 2004 09:16:25 -0700
Message-ID: <19b033c1.0405310816.2e5a9105@posting.google.com>


How can I tell which column has caused a ORA-01438: value larger than specified precision allows for this column?

I need to know because I'd like to return a meaningful error message, and I'd like to rely on check constraints as much as possible to implement these types of business rules.



create table tab1 (
col1 number(5),
col2 number(3));

create or replace procedure proc_ins (
param1 in tab1.col1%type,
param2 in tab1.col2%type,
errormess varchar2) is

begin
  insert into tab1 (col1,col2) values
  (param1,param2);
  commmit;
  errormess := 'no error';
exception
  when others errormess := SQLERRM;
end; Received on Mon May 31 2004 - 11:16:25 CDT

Original text of this message

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