Home » SQL & PL/SQL » SQL & PL/SQL » ORA 06502
ORA 06502 [message #185589] Wed, 02 August 2006 08:31 Go to next message
sweetgeegee27
Messages: 107
Registered: June 2005
Senior Member
Help anyone?

When the value 26688 is entered for TP.tax_payer_no it returns ORA 06502

begin

select NVL(CORP.REGIST_NAME,last_name||' '||first_name)
into :cg$ctrl.l_name
from CORPORATION CORP,
     individual  IND,
     TAX_PAYER TP
where TP.tax_payer_no = :cg$ctrl.taxpayer_no
 AND  CORP.TAX_PAYER_NO(+) = TP.TAX_PAYER_NO
 AND  IND.TAX_PAYER_NO(+) = TP.TAX_PAYER_NO;
exception
 when no_data_found then
    :cg$ctrl.l_name := '';
  
  -- ird_msg('This person does not exists','E',true);
  
end; 


Re: ORA 06502 [message #185593 is a reply to message #185589] Wed, 02 August 2006 08:41 Go to previous messageGo to next message
navkrish
Messages: 189
Registered: May 2006
Location: NJ,USA
Senior Member

Can u pls get us the description of table TAX_PAYER.

Naveen
Re: ORA 06502 [message #185595 is a reply to message #185593] Wed, 02 August 2006 08:45 Go to previous messageGo to next message
sweetgeegee27
Messages: 107
Registered: June 2005
Senior Member
TAX_PAYER_NO NOT NULL NUMBER(6)
TP_TYPE_NO NOT NULL NUMBER(2)
COUNTRY_NO NOT NULL NUMBER(3)
NSF_CHEQUE NOT NULL VARCHAR2(1)
CITY_NO NOT NULL NUMBER(3)
MAILING_ADDRESS VARCHAR2(45)
RESIDENT NOT NULL VARCHAR2(1)
REP_TAX_PAYER_NO NUMBER(6)
FISC_YR_START NOT NULL NUMBER(4)
FISC_YR_END NOT NULL NUMBER(4)
BRANCH_NO NUMBER(2)
REP_TYPE_NO NUMBER(2)
POST_CODE_NO NUMBER(5)
REP_REASON_NO NUMBER(2)
BANK_ACCT_NO VARCHAR2(15)
REP_TAXR_NAME VARCHAR2(40)
ENTER_DATE NOT NULL DATE
ENTER_USER NOT NULL NUMBER(3)
Re: ORA 06502 [message #185596 is a reply to message #185595] Wed, 02 August 2006 08:45 Go to previous messageGo to next message
sweetgeegee27
Messages: 107
Registered: June 2005
Senior Member
TAX_PAYER_NO            NOT NULL NUMBER(6)
 TP_TYPE_NO              NOT NULL NUMBER(2)
 COUNTRY_NO              NOT NULL NUMBER(3)
 NSF_CHEQUE              NOT NULL VARCHAR2(1)
 CITY_NO                 NOT NULL NUMBER(3)
 MAILING_ADDRESS                  VARCHAR2(45)
 RESIDENT                NOT NULL VARCHAR2(1)
 REP_TAX_PAYER_NO                 NUMBER(6)
 FISC_YR_START           NOT NULL NUMBER(4)
 FISC_YR_END             NOT NULL NUMBER(4)
 BRANCH_NO                        NUMBER(2)
 REP_TYPE_NO                      NUMBER(2)
 POST_CODE_NO                     NUMBER(5)
 REP_REASON_NO                    NUMBER(2)
 BANK_ACCT_NO                     VARCHAR2(15)
 REP_TAXR_NAME                    VARCHAR2(40)
 ENTER_DATE              NOT NULL DATE
 ENTER_USER              NOT NULL NUMBER(3)
Re: ORA 06502 [message #185605 is a reply to message #185596] Wed, 02 August 2006 10:06 Go to previous messageGo to next message
sweetgeegee27
Messages: 107
Registered: June 2005
Senior Member
Thanks, problem solved!! It had nothing to do with the tax_paye_no field. I had to increase the character length for the last_name
Re: ORA 06502 [message #185608 is a reply to message #185605] Wed, 02 August 2006 10:36 Go to previous messageGo to next message
sweetgeegee27
Messages: 107
Registered: June 2005
Senior Member
I was wrong. Problem still exists. Help anyone? I think it has to do with a exception handler.
Re: ORA 06502 [message #185611 is a reply to message #185608] Wed, 02 August 2006 11:12 Go to previous messageGo to next message
sweetgeegee27
Messages: 107
Registered: June 2005
Senior Member
Problem solved
Re: ORA 06502 [message #185613 is a reply to message #185611] Wed, 02 August 2006 11:32 Go to previous messageGo to next message
Littlefoot
Messages: 20896
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
If you keep the answers private, why do you bring problems in public?

Or should I have asked it vice versa?
Re: ORA 06502 [message #185617 is a reply to message #185613] Wed, 02 August 2006 12:46 Go to previous messageGo to next message
sweetgeegee27
Messages: 107
Registered: June 2005
Senior Member
Sorry. As I said earlier the problem was not with the tax_payer_no. I had to increase the maximum length for the name field.
Re: ORA 06502 [message #185618 is a reply to message #185617] Wed, 02 August 2006 12:47 Go to previous messageGo to next message
sweetgeegee27
Messages: 107
Registered: June 2005
Senior Member
Try not to sound so harsh next time.
Re: ORA 06502 [message #185685 is a reply to message #185618] Thu, 03 August 2006 02:09 Go to previous messageGo to next message
JRowbottom
Messages: 5933
Registered: June 2006
Location: Sunny North Yorkshire, ho...
Senior Member
Littlefoot has a valid point.
If you keep the solution to yourself, no-one else learns anything.
If you're asking us to share what we know to help you, wouldn't you say that it is incumbent on you to do the same to help others by letting people know how you solved the problem?
Re: ORA 06502 [message #185762 is a reply to message #185685] Thu, 03 August 2006 07:58 Go to previous message
sweetgeegee27
Messages: 107
Registered: June 2005
Senior Member
Point taken. I did apologise and gave the solution. Now can y'all please give me a break?
Previous Topic: XMLType and Oracle 9i
Next Topic: calculate the time difference
Goto Forum:
  


Current Time: Tue Dec 06 04:36:12 CST 2016

Total time taken to generate the page: 0.13611 seconds