Home » SQL & PL/SQL » SQL & PL/SQL » Statement Ignored 'Error Message occured while calling for RPAD'
Statement Ignored 'Error Message occured while calling for RPAD' [message #239646] Tue, 22 May 2007 23:26 Go to next message
kogilaah_k
Messages: 20
Registered: May 2007
Location: Malaysia
Junior Member
please help, i have been facing this probelm and not sure how to solve it...below is the part where the error message is showing

the error message that appears is :
PLS-00306: wrong number or types of arguments in call to 'RPAD'
PL/SQL: SQL Statement ignored.





FUNCTION DISPLAY_REPORT(
    P_MAX_LINE   IN NUMBER,
    P_ERR_MSG    OUT VARCHAR2
) RETURN NUMBER IS
   LINE_CNT NUMBER DEFAULT 0;
   PAGE_CNT NUMBER DEFAULT 0;

  BEGIN
       FOR IDX IN 0..P_MAX_LINE LOOP
       IF LINE_CNT = 0 THEN
         PAGE_CNT := PAGE_CNT + 1;
         PRINT_HEADER(PAGE_CNT);
         LINE_CNT := 0;
     END IF;


FND_FILE.PUT_LINE(FND_FILE.OUTPUT,LPAD(TO_CHAR(IDX+1),6) ||' '||
  RPAD(REC_VEND_NO(IDX),12)||' '|| RPAD(REC_VENDOR_NAME(IDX),42)
  ||' '||RPAD(REC_ITEM_NO(IDX),12)||' '||RPAD(REC_DESC(IDX),60)
  ||' '||RPAD(REC_CATEGORY(IDX),8)||' '||REC_COUNT(IDX));


      LINE_CNT := LINE_CNT + 1;

      IF LINE_CNT >= PAGE_LINE THEN
         LINE_CNT := 0;
         FND_FILE.PUT(FND_FILE.OUTPUT,CHR(12));
      END IF;

  END LOOP;
 IF LINE_CNT >=  PAGE_LINE THEN
         LINE_CNT := 0;
         FND_FILE.PUT(FND_FILE.OUTPUT,CHR(12));
         PAGE_CNT := PAGE_CNT + 1;
         PRINT_HEADER(PAGE_CNT);
  END IF;

       FND_FILE.PUT_LINE(FND_FILE.OUTPUT,' ');
       FND_FILE.PUT_LINE(FND_FILE.OUTPUT,RPAD(' ',60) ||
       '********** END OF REPORT **********');

  RETURN OK_RET;

  END DISPLAY_REPORT;


Re: Statement Ignored 'Error Message occured while calling for RPAD' [message #239663 is a reply to message #239646] Wed, 23 May 2007 00:36 Go to previous messageGo to next message
Frank
Messages: 7880
Registered: March 2000
Senior Member
RPAD(REC_VEND_NO(IDX),12)

What datatype is rec_vend_no?
Re: Statement Ignored 'Error Message occured while calling for RPAD' [message #239687 is a reply to message #239663] Wed, 23 May 2007 01:30 Go to previous messageGo to next message
kogilaah_k
Messages: 20
Registered: May 2007
Location: Malaysia
Junior Member
VARCHAR2
Re: Statement Ignored 'Error Message occured while calling for RPAD' [message #239692 is a reply to message #239687] Wed, 23 May 2007 01:45 Go to previous message
Michel Cadot
Messages: 64109
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
So what does "REC_VEND_NO(IDX)" mean?

Regards
Michel
Previous Topic: Regarding bulk update
Next Topic: Can you guyz check this code for me plz !!!
Goto Forum:
  


Current Time: Mon Dec 05 10:35:40 CST 2016

Total time taken to generate the page: 0.08116 seconds