Large DDL causes ORA-06502 in several Applications

I Created a Table with
CREATE TABLE large_table (
c001 VARCHAR(2) NOT NULL
and added columns with
ALTER TABLE large_table ADD c002 VARCHAR(2) NOT NULL;
ALTER TABLE large_table ADD c060 VARCHAR(2) NOT NULL;
The DDL of this table cannot be executed eg. in SqlDeveloper, sqlplus, ... and it cannot be imported from a dump with exp! Importing causes:
Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options
Export file created by EXPORT:V10.02.01 via conventional path
import done in WE8ISO8859P15 character set and AL16UTF16 NCHAR character set
. importing RLODEVEL's objects into RLODEVEL
. importing RLODEVEL's objects into RLODEVEL
IMP-00017: following statement failed with ORACLE error 604:
"CREATE TABLE "LARGE_TABLE" ("C001" VARCHAR2(2) NOT NULL ENABLE, "C002" VARC"
"HAR2(2) NOT NULL ENABLE, "C003" VARCHAR2(2) NOT NULL ENABLE, "C004" VARCHAR"
"2(2) NOT NULL ENABLE, "C005" VARCHAR2(2) NOT NULL ENABLE, "C006" VARCHAR2(2"
") NOT NULL ENABLE, "C007" VARCHAR2(2) NOT NULL ENABLE, "C008" VARCHAR2(2) N"
"OT NULL ENABLE, "C009" VARCHAR2(2) NOT NULL ENABLE, "C010" VARCHAR2(2) NOT "
"NULL ENABLE, "C011" VARCHAR2(2) NOT NULL ENABLE, "C012" VARCHAR2(2) NOT NUL"
"L ENABLE, "C013" VARCHAR2(2) NOT NULL ENABLE, "C014" VARCHAR2(2) NOT NULL E"
"NABLE, "C015" VARCHAR2(2) NOT NULL ENABLE, "C016" VARCHAR2(2) NOT NULL ENAB"
"LE, "C017" VARCHAR2(2) NOT NULL ENABLE, "C018" VARCHAR2(2) NOT NULL ENABLE,"
" "C019" VARCHAR2(2) NOT NULL ENABLE, "C020" VARCHAR2(2) NOT NULL ENABLE, "C"
"021" VARCHAR2(2) NOT NULL ENABLE, "C022" VARCHAR2(2) NOT NULL ENABLE, "C023"
"" VARCHAR2(2) NOT NULL ENABLE, "C024" VARCHAR2(2) NOT NULL ENABLE, "C025" V"
"ARCHAR2(2) NOT NULL ENABLE, "C027" VARCHAR2(2) NOT NULL ENABLE, "C026" VARC"
"HAR2(2) NOT NULL ENABLE, "C028" VARCHAR2(2) NOT NULL ENABLE, "C029" VARCHAR"
"2(2) NOT NULL ENABLE, "C030" VARCHAR2(2) NOT NULL ENABLE, "C031" VARCHAR2(2"
") NOT NULL ENABLE, "C032" VARCHAR2(2) NOT NULL ENABLE, "C033" VARCHAR2(2) N"
"OT NULL ENABLE, "C034" VARCHAR2(2) NOT NULL ENABLE, "C035" VARCHAR2(2) NOT "
"NULL ENABLE, "C036" VARCHAR2(2) NOT NULL ENABLE, "C037" VARCHAR2(2) NOT NUL"
"L ENABLE, "C038" VARCHAR2(2) NOT NULL ENABLE, "C039" VARCHAR2(2) NOT NULL E"
"NABLE, "C040" VARCHAR2(2) NOT NULL ENABLE, "C041" VARCHAR2(2) NOT NULL ENAB"
"LE, "C042" VARCHAR2(2) NOT NULL ENABLE, "C043" VARCHAR2(2) NOT NULL ENABLE,"
" "C044" VARCHAR2(2) NOT NULL ENABLE, "C045" VARCHAR2(2) NOT NULL ENABLE, "C"
"046" VARCHAR2(2) NOT NULL ENABLE, "C047" VARCHAR2(2) NOT NULL ENABLE, "C048"
"" VARCHAR2(2) NOT NULL ENABLE, "C049" VARCHAR2(2) NOT NULL ENABLE, "C050" V"
"ARCHAR2(2) NOT NULL ENABLE, "C051" VARCHAR2(2) NOT NULL ENABLE, "C052" VARC"
"HAR2(2) NOT NULL ENABLE, "C053" VARCHAR2(2) NOT NULL ENABLE, "C054" VARCHAR"
"2(2) NOT NULL ENABLE, "C055" VARCHAR2(2) NOT NULL ENABLE, "C056" VARCHAR2(2"
") NOT NULL ENABLE, "C057" VARCHAR2(2) NOT NULL ENABLE, "C058" VARCHAR2(2) N"
"OT NULL ENABLE, "C059" VARCHAR2(2) NOT NULL ENABLE, "C060" VARCHAR2(2) NOT "
"NULL ENABLE) PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 STORAGE(INITIAL"
" 65536 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT) TABLESPACE "USERS"
"" LOGGING NOCOMPRESS"
IMP-00003: ORACLE error 604 encountered
ORA-00604: error occurred at recursive SQL level 1
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
ORA-06512: at line 25
Import terminated successfully with warnings.
I'm quite sure, this problem is well known, but I did not find a hint in metalink or the rest of the internet.

Sorry, the example has not been tested well :(
But I just had to duplicate the number of columns to get the error both in SqlDeveloper, SqlPlus and (still) imp. That sqlplus and imp have different limits in DDL-size confuses me even more :-/
CREATE TABLE LARGE_TABLE (
C001 VARCHAR2(2) NOT NULL , C002 VARCHAR2(2) NOT NULL , C003 VARCHAR2(2) NOT NULL , C004 VARCHAR2(2) NOT NULL ,
C005 VARCHAR2(2) NOT NULL , C006 VARCHAR2(2) NOT NULL , C007 VARCHAR2(2) NOT NULL , C008 VARCHAR2(2) NOT NULL ,
C009 VARCHAR2(2) NOT NULL , C010 VARCHAR2(2) NOT NULL , C011 VARCHAR2(2) NOT NULL , C012 VARCHAR2(2) NOT NULL ,
C013 VARCHAR2(2) NOT NULL , C014 VARCHAR2(2) NOT NULL , C015 VARCHAR2(2) NOT NULL , C016 VARCHAR2(2) NOT NULL ,
C017 VARCHAR2(2) NOT NULL , C018 VARCHAR2(2) NOT NULL , C019 VARCHAR2(2) NOT NULL , C020 VARCHAR2(2) NOT NULL ,
C021 VARCHAR2(2) NOT NULL , C022 VARCHAR2(2) NOT NULL , C023 VARCHAR2(2) NOT NULL , C024 VARCHAR2(2) NOT NULL ,
C025 VARCHAR2(2) NOT NULL , C027 VARCHAR2(2) NOT NULL , C026 VARCHAR2(2) NOT NULL , C028 VARCHAR2(2) NOT NULL ,
C029 VARCHAR2(2) NOT NULL , C030 VARCHAR2(2) NOT NULL , C031 VARCHAR2(2) NOT NULL , C032 VARCHAR2(2) NOT NULL ,
C033 VARCHAR2(2) NOT NULL , C034 VARCHAR2(2) NOT NULL , C035 VARCHAR2(2) NOT NULL , C036 VARCHAR2(2) NOT NULL ,
C037 VARCHAR2(2) NOT NULL , C038 VARCHAR2(2) NOT NULL , C039 VARCHAR2(2) NOT NULL , C040 VARCHAR2(2) NOT NULL ,
C041 VARCHAR2(2) NOT NULL , C042 VARCHAR2(2) NOT NULL , C043 VARCHAR2(2) NOT NULL , C044 VARCHAR2(2) NOT NULL ,
C045 VARCHAR2(2) NOT NULL , C046 VARCHAR2(2) NOT NULL , C047 VARCHAR2(2) NOT NULL , C048 VARCHAR2(2) NOT NULL ,
C049 VARCHAR2(2) NOT NULL , C050 VARCHAR2(2) NOT NULL , C051 VARCHAR2(2) NOT NULL , C052 VARCHAR2(2) NOT NULL ,
C053 VARCHAR2(2) NOT NULL , C054 VARCHAR2(2) NOT NULL , C055 VARCHAR2(2) NOT NULL , C056 VARCHAR2(2) NOT NULL ,
C057 VARCHAR2(2) NOT NULL , C058 VARCHAR2(2) NOT NULL , C059 VARCHAR2(2) NOT NULL , C060 VARCHAR2(2) NOT NULL ,
C101 VARCHAR2(2) NOT NULL , C102 VARCHAR2(2) NOT NULL , C103 VARCHAR2(2) NOT NULL , C104 VARCHAR2(2) NOT NULL ,
C105 VARCHAR2(2) NOT NULL , C106 VARCHAR2(2) NOT NULL , C107 VARCHAR2(2) NOT NULL , C108 VARCHAR2(2) NOT NULL ,
C109 VARCHAR2(2) NOT NULL , C110 VARCHAR2(2) NOT NULL , C111 VARCHAR2(2) NOT NULL , C112 VARCHAR2(2) NOT NULL ,
C113 VARCHAR2(2) NOT NULL , C114 VARCHAR2(2) NOT NULL , C115 VARCHAR2(2) NOT NULL , C116 VARCHAR2(2) NOT NULL ,
C117 VARCHAR2(2) NOT NULL , C118 VARCHAR2(2) NOT NULL , C119 VARCHAR2(2) NOT NULL , C120 VARCHAR2(2) NOT NULL ,
C121 VARCHAR2(2) NOT NULL , C122 VARCHAR2(2) NOT NULL , C123 VARCHAR2(2) NOT NULL , C124 VARCHAR2(2) NOT NULL ,
C125 VARCHAR2(2) NOT NULL , C127 VARCHAR2(2) NOT NULL , C126 VARCHAR2(2) NOT NULL , C128 VARCHAR2(2) NOT NULL ,
C129 VARCHAR2(2) NOT NULL , C130 VARCHAR2(2) NOT NULL , C131 VARCHAR2(2) NOT NULL , C132 VARCHAR2(2) NOT NULL ,
C133 VARCHAR2(2) NOT NULL , C134 VARCHAR2(2) NOT NULL , C135 VARCHAR2(2) NOT NULL , C136 VARCHAR2(2) NOT NULL ,
C137 VARCHAR2(2) NOT NULL , C138 VARCHAR2(2) NOT NULL , C139 VARCHAR2(2) NOT NULL , C140 VARCHAR2(2) NOT NULL ,
C141 VARCHAR2(2) NOT NULL , C142 VARCHAR2(2) NOT NULL , C143 VARCHAR2(2) NOT NULL , C144 VARCHAR2(2) NOT NULL ,
C145 VARCHAR2(2) NOT NULL , C146 VARCHAR2(2) NOT NULL , C147 VARCHAR2(2) NOT NULL , C148 VARCHAR2(2) NOT NULL ,
C149 VARCHAR2(2) NOT NULL , C150 VARCHAR2(2) NOT NULL , C151 VARCHAR2(2) NOT NULL , C152 VARCHAR2(2) NOT NULL ,
C153 VARCHAR2(2) NOT NULL , C154 VARCHAR2(2) NOT NULL , C155 VARCHAR2(2) NOT NULL , C156 VARCHAR2(2) NOT NULL ,
C157 VARCHAR2(2) NOT NULL , C158 VARCHAR2(2) NOT NULL , C159 VARCHAR2(2) NOT NULL , C160 VARCHAR2(2) NOT NULL
PCTFREE 10
PCTUSED 40
INITRANS 1
MAXTRANS 255
STORAGE(INITIAL 65536 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
TABLESPACE USERS
LOGGING
NOCOMPRESS
CREATE TABLE LARGE_TABLE (
ERROR at line 1:
ORA-00604: error occurred at recursive SQL level 1
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
ORA-06512: at line 25

Similar Messages

  • Ora -06502 from forms application

    I have medical application developed by forms 9i, But its responds error
    ORA-06502 while running a form with enter query mode. it displys the said
    error while execute the query . I dont the exeact SQL query returns this error. How to debug this? Is there any way how to find the sql text returns this error. Kinldy note that, I dont have the forms source code. Only executable available(fmx). I have TOAD too. can i use the toad to traceout it.
    thanks.

    Hi,
    This is ' numeric or value error' it may be character to number conversion problem or your assigning character value to number field in the form.....But without source code It's not easy to solve the problem....
    Thanks,
    Pavan.

  • Download BLOB in Report causes ORA-06502

    I built a page with a report showing a table of files and some more information.
    When i view the page the report shows the ORA-06502 error.
    I use this format to build the download link:
    DOWNLOAD:OVV_HANDBUCH:DATEI:ID::MIMETYPE:DATEINAME:::attachment:Herunterladen
    The Table is called ovv_handbuch
    The PK column: id
    The blob column: datei
    The filename column: dateiname
    The mimetype column: mimetype
    Does perhaps the charset WE8MSWIN1252 of the database could be a problem?

    Hi,
    You can install Demonstrative application to your workspace and check there how that report can be done
    To install demo app:
    Home>Create Application and select Demonstration Application
    Check then page 3 report
    Br,Jari

  • List of Values  Rerort error :ORA-06502

    Hi,
    I have one LOV is query based,
    My selected table have between 818 and 2000 rows.
    Now, report error:
    ORA-20001: Error fetching column value: ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    Item Type (Select lisrt query based LOV)
    Help !
    Regards from Azerbaijan.

    Mahir - Select list queries are limited as to how much they can return. There are a couple of limits that factor into the formula so I can't give you an exact number of rows. I suggest you use a popup LOV instead, your page will be much lighter.
    See:
    Re: htmldb_item.select_list causes ORA-06502: PL/SQL: numeric or value erro
    Re: Error while associating a report column with a LOV
    Scott
    Message was edited by:
    sspadafo

  • ORA-06502: PL/SQL: numeric or value error: number precision too large

    I am getting this error when my procedure is being invoked. I've checked if a calculation is attemting to assign an integer to a column that has a smaller data type...e.g 99 being inserted into NUMBER(2)....but this all seems fine...
    any ideas where I should check?
    thanks!

    >Is there a way to tell which column is throwing this error
    As suggested by Guido it appears to be related to your variables, not the table;
    SQL> create table t (col1 number(1))
    Table created.
    SQL> begin
       insert into t values (11);
    end;
    ORA-01438: value larger than specified precision allowed for this column
    ORA-06512: at line 2
    SQL> declare
       n  number(1);
       n2 number(2) :=11;
    begin
       n:= n2;
    end;
    ORA-06502: PL/SQL: numeric or value error: number precision too large
    ORA-06512: at line 5The error message should tell you the line of code that is causing the problem, ie;
    ORA-06512: at line 5A quick way to show the values is to display them using dbms_output.put_line inline or in the exception handler.

  • ORA-06502 (character string buffer too small) on import application via script

    Running apex 4.2.2.00.11
    oracle 10.2.0.5
    I'm using a script to import my development application to a few production applications.
    It worked great on apex 4.1.1, but now I get an 'ORA-06502 PL/SQL numeric of value error: character string buffer too small'
    In the command window, I see that the script fails after it starts on the plugins.
    My question: is this a bug in 4.2.2?
    I could be a incompatible plugin, but how can I found out which plugin?
    My script is quite simple:
    In a command window I run
    sqlplus SCHEMA/PASSWORD@SPIEU10 @_IMPORT_F102.sql
    The script is
    declare
    l_workspace_id number;
    begin
        -- determine the workspace id for the workspace FM in the target system
        select workspace_id into l_workspace_id from apex_workspaces where workspace = 'BY_APEX_SHARED';
        -- set the context for the target workspace
        apex_application_install.set_workspace_id( l_workspace_id );
        -- override the original application id 102
        apex_application_install.set_application_id ( 102 );
        -- set a different application name and alias, it should be unique within an APEX instance
        apex_application_install.set_application_alias( 'MY_ALIAS' );
        apex_application_install.set_application_name( 'MY_APP_NAME' );
        -- Use fixed offset
        apex_application_install.set_offset( p_offset => 0);
        -- override the original parsing schema FM with a different value
        apex_application_install.set_schema( 'BY_SCHEMA' );
    end;
    -- install the original application export, now the values for the workspace
    @f102.sql
    exit;
    Error message from command window:
    ...ui types
    ...plugins
    begin
    ERROR at line 1:
    ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    ORA-06512: at line 3
    Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64
    bit Production
    With the Partitioning, Data Mining and Real Application Testing options

    ListAGG throws an ORA-01489 for varchar2 > 4000 bytes
    OP has an ORA-06502 --> the IR is running into a 4k/32k limit.
    quick solution: wrap USER_COMMENTS ListAGG in a substr( ...., 1, 4000)
    Longer solution, use a subquery to modify the comments based on ROW_NUMBER() (ie after nth row, change it to NULL)
    with
    -- simulating data
    t as (select task_id, sysdate - lv as date_entered
      ,round(dbms_random.value(1,24)) hours
      , '-*' || lv || '.' || task_id || '*-' as user_comments
    from ( select level as task_id from dual connect by level <=10 ), (select level lv from dual connect by level < 1000)
    -- modify data
    modified_data as (
      select task_id, hours, date_entered
        ,case
          when row_number() over (partition by task_id order by date_entered desc) < 5
            then user_comments
          else null
         end USER_COMMENTS
        from t)
    select task_id, sum(hours) total_hours,
      listagg( user_comments  ) within group (order by date_entered desc)
      || case when count(*) >= 5 then '! MORE COMMENTS !' else null end
        as user_comments
    from modified_data
    group by task_id;

  • Application Builder page ORA-06502

    I'm having the same problem as described in this old thread that doesn't seem to have been resolved:
    application builder page error ORA-06502
    After logging in, I click Application Builder and get this error message three times:
    report error:
    ORA-06502: PL/SQL: numeric or value error: NULL index table key value
    On the main part of the page where there should be a bunch of icons for each of the applications, and also on the right in the boxes labeled "Recent" and "Application Groups". The URL states that I'm in application 4000, page 1500. Using info from the old thread I tried changing the view option of the report from "Icons" to "Details" and find I am able to see the list of applications this way. I am worried that eventually even this method of reaching my application will become compromised. Anyone know how to fix this issue yet?
    My versions are:
    Application Express 3.2.1.00.12
    Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bit Production
    With the Partitioning, OLAP and Data Mining options

    So after a while the problem went away by itself, but it's back again and I've noticed another section of APEX that becomes affected when this error starts happening. When I click the icon for Copy Region, instead of a list of region names I get the error message.

  • ORA-06502 on Application edit page

    I have a strange problem. When I entered the application: page +"Home>Application Builder>Application 106"+ this morning it display the following error where it usually display the lists of pages:
    report error:
    ORA-06502: PL/SQL: numeric or value error: NULL index table key value
    It is the same for all the applications on this user. (I do not have other users with applications so I'm uncertain if it is a user problem or a global problem). If I run the application I can still navigate to a page and edit the page. The only thing that seems to be broken is the page listing on the first page. Any idea how to solve this?

    Hi,
    This might help
    ORA-06502: PL/SQL: numeric or value error: NULL index table key value
    Br,Jari

  • Application builder page error ORA-06502

    We get an intermittent error with the application builder page of application express. The report that normally shows the icons or rows for each application returns the error "report error:
    ORA-06502: PL/SQL: numeric or value error: NULL index table key value". is this a know issue? is there anything we can do to fix it?
    Tom

    Scott,
    Thanks for the reply.
    I will try my best to explain, following is the navigation:
    1. After logging into my workspace --> Click on Application Builder --> Click either on a custom application or sample application --> I get report error: ORA-06502: PL/SQL: numeric or value error: NULL index table key value (Default View of the pages is set to Details)
    2. If I change the page[s] View to Icons then there is no error.
    3. We bounced the web but still having the error, did not try flushing the shared pool on the server.
    HTH
    Thanks
    Pradeep
    PS: How can I upload a screenshot?

  • Listener Error - character string buffer too small (ORA-06502)

    I am running into a very strange problem with the APEX listener on seemingly random pages. I can hit every page in my application just fine, but as soon as I hit this specific one, Glassfish throws an HTTP 500 error. If I click Debug, the page seems to load fine with no indications of trouble, but as soon as I turn debug back off, it goes back to the HTTP 500 error. I don't see anything special about the page that makes this happen. It is pretty simple and has 4 regions. I have noticed that if I set any 1 of the 4 regions to "Never display", the page loads fine. It's like having all 4 of them enabled at once are causing some overload, even though it's actually a smaller amount of data than most of my other pages.
    **Update: I just discovered this only happens if I'm logged into the workspace first and then try to run the page! If I log out of APEX and then hit the application as a normal user, page loads error-free. This is still an annoying problem, but at least it seems I have a decent workaround since regular users never see it.
    After a couple days, I noticed the exact same problem on a second APEX application I'm using. Again, it is on some random page whereas all the other pages work fine.
    Both applications and pages in question worked without issue in APEX 3.x. I am trying to get an APEX application up and running on the latest version.
    I have tried both Glassfish server and simply downloading the latest listener (version 1.1.1) and running it in standalone mode. I get the problem both ways, which is why it seems it's a listener issue.
    I have seen a few other threads of people having this problem, but I never did find anyone with a solution, and most of the posts stopped back in December.
    Some details on my environment:
    Database version: Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bi
    APEX version: 4.0.2
    Webserver: Glassfish 3.1
    Here is the log entry from Glassfish when the HTTP 500 error displays as I try to load one of the bugged pages.
    [#|2011-05-10T21:14:22.967-0500|INFO|oracle-glassfish3.1|javax.enterprise.system.std.com.sun.enterprise.server.logging|_ThreadID=111;_ThreadName=Thread-1;|MaxConnectionReuseCount=50000|#]
    [#|2011-05-10T21:14:46.431-0500|SEVERE|oracle-glassfish3.1|javax.enterprise.system.std.com.sun.enterprise.server.logging|_ThreadID=112;_ThreadName=Thread-1;|
    ***********ERROR***********
    init: # headers=46
    declare nm owa.vc_arr := ?;
    vl owa.vc_arr := ?;
    begin
    owa.init_cgi_env( ?, nm, vl );
    htp.init; htp.HTBUF_LEN := 63;
    ? := sys_context('USERENV','SID');
    end;
    SID:1242
    CALL:
    begin
    f(p=>?);
    commit;
    end;
    BINDS
    p:100:2:220529248574492::NOPAGE CALL:
    declare
    nlns number := 999999;
    l_clob CLOB;
    lines htp.htbuf_arr;
    l_buff varchar2(32767);
    l_clob_init boolean:= false;
    l_file varchar2(5);
    l_doc_info varchar2(1000);
    begin
    OWA.GET_PAGE(lines, nlns);
    if (nlns > 1) then
    for i in 1..nlns loop
    if ( length(lines(i)) > 0 ) then
    if ( ( lengthb(l_buff) + lengthb(lines(i))) > 32767) then
    if (NOT l_clob_init) then
    dbms_lob.createtemporary(l_clob, TRUE);
    dbms_lob.open(l_clob, dbms_lob.lob_readwrite);
    l_clob_init:=true;
    end if;
    dbms_lob.writeappend(l_clob,length(l_buff),l_buff);
    l_buff := lines(i);
    else
    l_buff := l_buff || lines(i);
    end if;
    end if;
    end loop;
    end if;
    if (l_clob_init) then
    dbms_lob.writeappend(l_clob,length(l_buff),l_buff);
    l_buff := '';
    end if;
    ? := l_clob;
    ? := l_buff;
    if (wpg_docload.is_file_download) then l_file:='TRUE'; wpg_docload.get_download_file(l_doc_info); else l_file := 'FALSE'; end if; ? := l_file;
    ? := l_doc_info;
    end;
    get_page FAILED:ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    ORA-06512: at line 33
    Edited by: BrianB on May 11, 2011 7:50 AM
    Edited by: BrianB on May 11, 2011 8:01 AM

    Brian,
    this post is going to get a bit longer, so the summary comes first.
    h6. Summary
    1. I could reproduce the problem on my system using the APEX Listener in standalone mode.
    2. I don't think the problem is content-related in the sense that you have any issue in your page or database contents.
    3. I have a workaround for your problem.
    h6. Error message
    Having that error in my environment made me start to think. I not only disabled some item and got it work, but I could also add something to achieve this effect.
    So I came to think, this really is somewhere deep down. The error message doesn't seem very helpful on first sight, but when starting to follow on what's happening there, things get clearer:
    APEX generates pages dynamically, replacing substitution strings and other tokens to get the actual page definition. This has to be read by a requesting client. The use of VARCHAR2 as buffer introduces a limit of 32767 bytes, after which the contents is handled as CLOB instead.
    h6. Analysis
    Obviously, there are cases where the "estimation" fails. Of course, this is may only be relevant in rare cases, because:
    1. If a page would exceed the maximum without some charset interpretation problem, the buffer would be switched to clob.
    2. If a page stays small enough to stay below 32767 even with some characters that are acutally larger then expected, the buffer isn't busted.
    To find out, if your could be one of these rare cases, I investigated the HTTP headers, focussing on X-DB-Content-length and made an odd observation.
    Test case 1: "Go" button disabled, so the page runs fine with APEX Listener
    1. It has *31968 bytes* when coming from APEX Listener with a Go button disabled.
    2. It has *31938 bytes* according to the header set by EPG - for exactly the same page.
    That makes a difference of 30 bytes for what is expected to be the same contents.
    Test case 2: The button is enabled again
    1. This causes the page load to crash in APEX Listener.
    2. EPG transports *32341 bytes* according to that header.
    So we are pretty close to the hard limit for the VARCHAR2 buffer.
    For some reason, APEX Listener seems to cause a false calculation of the actual page size. Whether this is due to some charset problem or due to some other problem with response handling, I don't know. The 30 bytes difference may result from the odd header "X-ORACLE-IGNORE" with value "IGNORE, IGNORE, IGNORE, IGNORE" sent by the APEX Listener. This value has exactly 30 bytes in length, but this could be coincidence, as there are more differences in headers. If I add the size of all headers, we are even closer to the buffer limit and probably exceed it when some items need more bytes than expected.
    This could even be as simple as a line break, as your page has about 424 lines when I disabled the button... Adding 1 byte per line to the 32341 bytes of the EPG, I get 32765 bytes. Now add that button (403 bytes difference on EPG) and you exceeed the limit. Reduce that value by the line count again and you are still below.
    Could be coincidence as well, but makes me wonder.
    h6. Workaround
    To make sure that we were actually hitting that limit, I now introduce my suggestion for a workaround.
    Test case 3: Add a hidden item
    1. APEX Listener loads the page, stating the size to be *32876 bytes*
    2. EPG sees 30 bytes less and transmits the header with *32846 bytes*
    h6. Conclusion
    I can't give you a real solution for that problem, nor do I have a definitive answer on what is the root cause for it. It seems, only one of the developers may find it. But I can offer you a workaround, which is to just add some hidden item to your page so it exceeds the limit for the VARCHAR2 buffer and gets handled as clob.
    Note that this may occur outside the app builder as well. The app builder just renders some additional items when starting that page, so it has a different size from its productive representation. On the other hand, I may start counting the size of that additional page section - I wouldn't wonder if that results in a value around 400 bytes, and this is the forgotten part...
    Unfortunately, if it actually is happening outside of the app builder, this workaround isn't very handy: Dynamic contents can't be calculated that easy all the time, so you may have cases where you just don't know in advance if you are close to the limit and have to add some item to exceed it or if you've already exceeded it or if you are far below, or close enough to actually hit it when adding just one byte...
    -Udo

  • Ora-06502 numeric or value error --urgent

    Hai ALL,
    In our Application some fields are blank and gives an error 'ora-06502 numeric or value error'. The blanked Fields are taken from another server. Before the error some os booting problem arises and reboot the server. no oracle maintanace and software maintanace done this place. the network connectivity is ok. How the oracle error comes? how to rectify ..please help.. Oracle version is 7..and an urgent matter.
    Shiju

    Hi Orashiju,
    ORA-06502:     PL/SQL: numeric or value error string
    Cause:     An arithmetic, numeric, string, conversion, or constraint error occurred. For example, this error occurs if an attempt is made to assign the value NULL to a variable declared NOT NULL, or if an attempt is made to assign an integer larger than 99 to a variable declared NUMBER(2).
    Action:     Change the data, how it is manipulated, or how it is declared so that values do not violate constraints.
    For more use this link. I am certain you will get an solution.
    http://ora-06502.ora-code.com/
    Thanks
    Shivank

  • ORA-20001 and ORA-06502

    Hi all,
    after 6 months, my production application starts to show the same error on the report:
    ORA-20001: Error fetching column value: ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    The error occurs in the same type of page (form based on a table where i added a report with details) and if i change the column with Display As LOV (not save the state) with standard Report Column all works fine and if change again to Display As LOV (not save the state) dosn't work.
    At the moment i changed all query of the report to don't use the Display As LOV (not save the state) in the report, but why the application now get this error?
    Thanks,
    Sergio

    Sergio - I'm surprised that a hundred rows causes the Display As Text (based on LOV, save/does not save the state) to blow out. I'd expect no problems up to 5000 rows or so. I'd like to see an example of your case. The limitation on select lists is usually related to either the size of an individual report column (4000 max) or the size of a report row (32K max) in which a select-list lov is used. The total size of the HTML returned counts towards these limits. The problem for select-list items on a page is that large select lists mean lots of HTML on the page making the page heavy and burdening the network.
    Scott

  • Invalid function body condition: ORA-06502: PL/SQL: numeric or value error:

    I'm trying to customize my link column on an interactive report to branch to another page in my application based on a pl/sql call. My condition type for the link column is pl/sql function body returning a boolean. I'm calling a packaged function that returns a boolean but receive the following error:
    Invalid function body condition: ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    This is my code:
    return files_util.list_files('test','test');
    I've tried running the same code in sqlplus and it works fine. Any help would be appreciated.
    Thanks,
    Rob

    It turns out I had multiple issues. I thought the code I was running for the link column would be executed and let me branch to another page to view the results of my pl/sql code. It appears that the pl/sql code for the link column only controls whether the link is displayed or not. The reason for the ora-6502 was because a variable in my pl/sql function was not large enough to hold a value based on the userid signing onto the application. I'm using database authentication so I thought that the userid in apex would be my database userid which is only 4 characters. The userid actually used is apex_public_user which caused by ora-6502 error.

  • Java.sql.SQLException: ORA-06502: PL/SQL in EBS R12

    Hi everyone,
    May you please help me diagnose the problem.
    Oracle EBS 12.0.0.6, DB(10.2.0.3) on one machine and App(forms, concurrent manager, etc) on other machine, both AIX 5.3.
    I have following failed concurrent request:
    *====================================================*
    Payables: Version : 12.0.0
    Copyright (c) 1979, 1999, Oracle Corporation. All rights reserved.
    APPPBR module: AP Prepayment Balance Report
    Current system time is 12-MAY-2010 15:33:36
    XDO Data Engine Version No: 5.6.3
    Resp: 50661
    Org ID : 81
    Request ID: 449826
    All Parameters: ORG_ID_PARAM=81:COA_ID_PARAM=50328:FROM_DATE_PARAM="2010/05/12 00:00:00":TO_DATE_PARAM=:PERIOD_FROM_PARAM=JUL-09:PERIOD_TO_PARAM=MAY-
    10:CURR_CODE_PARAM=:ACCOUNT_FROM_PARAM=:ACCOUNT_TO_PARAM=:SUPPLIER_FROM_PARAM=Adel Bin Abdullah Bin Taha Al
    Hadad:SUPPLIER_TO_PARAM=:PAID_ONLY_PARAM=:POSTED_ONLY_PARAM=:DUMMY_PARAM=2
    Data Template Code: APPPBR
    Data Template Application Short Name: SQLAP
    Debug Flag: N
    {ORG_ID_PARAM=81, PERIOD_FROM_PARAM=JUL-09, CURR_CODE_PARAM=, DUMMY_PARAM=2, PAID_ONLY_PARAM=, PERIOD_TO_PARAM=MAY-10, POSTED_ONLY_PARAM=,
    ACCOUNT_FROM_PARAM=, SUPPLIER_FROM_PARAM=Adel Bin Abdullah Bin Taha Al Hadad, SUPPLIER_TO_PARAM=, TO_DATE_PARAM=, ACCOUNT_TO_PARAM=,
    FROM_DATE_PARAM=2010/05/12 00:00:00, COA_ID_PARAM=50328}
    Calling XDO Data Engine...
    [051210_033341921][][STATEMENT] Start process Data
    [051210_033341922][][STATEMENT] Process Data ...
    [051210_033341924][][STATEMENT] Executing data triggers...
    [051210_033341924][][STATEMENT] BEGIN
    AP_BAL_PKG.ORG_ID_PARAM := :ORG_ID_PARAM ;
    AP_BAL_PKG.COA_ID_PARAM := :COA_ID_PARAM ;
    AP_BAL_PKG.FROM_DATE_PARAM := :FROM_DATE_PARAM ;
    AP_BAL_PKG.TO_DATE_PARAM := :TO_DATE_PARAM ;
    AP_BAL_PKG.PERIOD_FROM_PARAM := :PERIOD_FROM_PARAM ;
    AP_BAL_PKG.PERIOD_TO_PARAM := :PERIOD_TO_PARAM ;
    AP_BAL_PKG.CURR_CODE_PARAM := :CURR_CODE_PARAM ;
    AP_BAL_PKG.ACCOUNT_FROM_PARAM := :ACCOUNT_FROM_PARAM ;
    AP_BAL_PKG.ACCOUNT_TO_PARAM := :ACCOUNT_TO_PARAM ;
    AP_BAL_PKG.SUPPLIER_FROM_PARAM := :SUPPLIER_FROM_PARAM ;
    AP_BAL_PKG.SUPPLIER_TO_PARAM := :SUPPLIER_TO_PARAM ;
    AP_BAL_PKG.PAID_ONLY_PARAM := :PAID_ONLY_PARAM ;
    AP_BAL_PKG.POSTED_ONLY_PARAM := :POSTED_ONLY_PARAM ;
    AP_BAL_PKG.DUMMY_PARAM := :DUMMY_PARAM ;
    :XDO_OUT_PARAMETER := 1;
    END;
    [051210_033341927][][STATEMENT] 1:81 :
    [051210_033341928][][STATEMENT] 2:50328 :
    [051210_033341928][][STATEMENT] 3:2010/05/12 00:00:00 :
    [051210_033341928][][STATEMENT] 4: :
    [051210_033341928][][STATEMENT] 5:JUL-09 :
    [051210_033341928][][STATEMENT] 6:MAY-10 :
    [051210_033341928][][STATEMENT] 7: :
    [051210_033341928][][STATEMENT] 8: :
    [051210_033341928][][STATEMENT] 9: :
    [051210_033341928][][STATEMENT] 10:Adel Bin Abdullah Bin Taha Al Hadad :
    [051210_033341928][][STATEMENT] 11: :
    [051210_033341928][][STATEMENT] 12: :
    [051210_033341929][][STATEMENT] 13: :
    [051210_033341929][][STATEMENT] 14:2 :
    [051210_033341940][][EXCEPTION] SQLException encounter while executing data trigger....
    java.sql.SQLException: ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    ORA-06512: at line 11
         at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:331)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:288)
         at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:745)
         at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:215)
         at oracle.jdbc.driver.T4CCallableStatement.executeForRows(T4CCallableStatement.java:965)
         at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1170)
         at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3339)
         at oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStatement.java:3445)
         at oracle.jdbc.driver.OracleCallableStatement.execute(OracleCallableStatement.java:4395)
         at oracle.apps.xdo.dataengine.XMLPGEN.executeTriggers(XMLPGEN.java:650)
         at oracle.apps.xdo.dataengine.XMLPGEN.processData(XMLPGEN.java:262)
         at oracle.apps.xdo.dataengine.XMLPGEN.processXML(XMLPGEN.java:215)
         at oracle.apps.xdo.dataengine.XMLPGEN.writeXML(XMLPGEN.java:254)
         at oracle.apps.xdo.dataengine.DataProcessor.processDataStructre(DataProcessor.java:390)
         at oracle.apps.xdo.dataengine.DataProcessor.processData(DataProcessor.java:355)
         at oracle.apps.xdo.oa.util.DataTemplate.processData(DataTemplate.java:348)
         at oracle.apps.xdo.oa.cp.JCP4XDODataEngine.runProgram(JCP4XDODataEngine.java:293)
         at oracle.apps.fnd.cp.request.Run.main(Run.java:157)
    Start of log messages from FND_FILE
    End of log messages from FND_FILE
    Executing request completion options...
    ------------- 1) PUBLISH -------------
    Beginning post-processing of request 449826 on node EBSCL1 at 12-MAY-2010 15:33:42.
    Post-processing of request 449826 failed at 12-MAY-2010 15:33:42 with the error message:
    One or more post-processing actions failed. Consult the OPP service log for details.
    Finished executing request completion options.
    Concurrent request completed
    Current system time is 12-MAY-2010 15:33:42
    *====================================================*
    When I look at OPP Log, following is the info:
    *====================================================*
    [5/12/10 3:33:42 PM] [OPPServiceThread0] Post-processing request 449826.
    [5/12/10 3:33:42 PM] [28164:RT449826] Executing post-processing actions for request 449826.
    [5/12/10 3:33:42 PM] [28164:RT449826] Starting XML Publisher post-processing action.
    [5/12/10 3:33:42 PM] [28164:RT449826]
    Template code: APPPBR
    Template app: SQLAP
    Language: en
    Territory: US
    Output type: RTF
    [5/12/10 3:33:42 PM] [UNEXPECTED] [28164:RT449826] java.lang.reflect.InvocationTargetException
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
         at java.lang.reflect.Method.invoke(Method.java:615)
         at oracle.apps.xdo.common.xml.XSLT10gR1.invokeParse(XSLT10gR1.java:517)
         at oracle.apps.xdo.common.xml.XSLT10gR1.transform(XSLT10gR1.java:224)
         at oracle.apps.xdo.common.xml.XSLTWrapper.transform(XSLTWrapper.java:177)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:1044)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:997)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:212)
         at oracle.apps.xdo.template.FOProcessor.createFO(FOProcessor.java:1665)
         at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:975)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.runProcessTemplate(TemplateHelper.java:5926)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3458)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3547)
         at oracle.apps.fnd.cp.opp.XMLPublisherProcessor.process(XMLPublisherProcessor.java:259)
         at oracle.apps.fnd.cp.opp.OPPRequestThread.run(OPPRequestThread.java:172)
    Caused by: oracle.xdo.parser.v2.XMLParseException: Start of root element expected.
         at oracle.xdo.parser.v2.XMLError.flushErrors1(XMLError.java:337)
         at oracle.xdo.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:343)
         at oracle.xdo.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:285)
         at oracle.xdo.parser.v2.XMLParser.parse(XMLParser.java:289)
         ... 17 more
    [5/12/10 3:33:42 PM] [28164:RT449826] Completed post-processing actions for request 449826.
    *====================================================*
    Br,
    Anjum

    Hi,
    It seems like a bug as per metalink note:
    APPPBR : AP Prepayment Balance Report Error Out java.sql.SQLException: ORA-06502: PL/SQL: numeric or value error: character string buffer too small ORA-06512: at line 11 [ID 827325.1]
    Anyway, if you have any relevant information, please share.
    Br,
    Anjum

  • ORA-06502 : PL/SQL: numeric or value error in Report formattrigger

    Hi guys,
    I have a Format Trigger code to not display any amount less than 1.00 at a group frame level and outside of the group frame is the Grand Total in my report but I am getting
    " REP-1401: ' r_headerformattrigger ' : Fatal PL/SQL error occurred.
    "ORA-06502 : PL/SQL: numeric or value error"
    every time I try to run it.
    function R_headerFormatTrigger return boolean is
    begin
    if :c_header_amount_accrual1_disp > 0.99 then
    return (TRUE);
    else
    return (FALSE);     
    end if;
    end;
    Does any one have any idea as why?

    read this code
    Cause: An arithmetic, numeric, string, conversion, or constraint error occurred. For example, this error occurs if an attempt is made to assign the value NULL to a variable declared NOT NULL, or if an attempt is made to assign an integer larger than 88 to a variable declared NUMBER(2).
    Action: Change the data, how it is manipulated, or how it is declared so that values do not violate constraints
    Rizwan

Maybe you are looking for

  • Integration Endeca and CRS - ATG 10.1.2 (Page Not Found)

    Dear Colleagues, Need your help. 1. I installed the following components: - MDEX 6.4.0 - CAS 3.1.1 - PlatformService 6.1.3 - TaF 3.1.1 - ATG 10.1.2 - Platform + CRS 2. Add the flowing config to prod server ApplicationConfiguration.properties: #Proper

  • My serial number is registered to another Apple ID

    my serial number is registered to another Apple ID, my iphone is new i tried to register my iphone serial number to my id but i got this massege....(According to our records, this serial number is registered to another Apple ID. If you have more than

  • Menu item stroke problems

    I am unable to add a right aligned stroke on the word 'Snowdon Super Cup' because the border cuts across the word 'Cup'. (the stroke appears where the word 'Cup' starts) How to I extend the border area in order for the menu item 'Snowdon Super Cup' t

  • Realy angry!-i cant make playlist sorted as what i want ??

    im realy angry and hope for nothing but i think there is no soultion for me.. my problem is - i mad a new playlist of my own and put some songs there (like 50 songs) and then.. i moved and edit the sort of the song manualy - you know like drging from

  • Keep Mac Mail from Deleting Emails On Server

    I have 2 Yahoo! acc'ts linked to Mac Mail. On the first acc't, after all my emails downloaded, I then deleted all the emails in Mac Mail (didn't need them). When I logged back into my acc't in Yahoo! (on browser), I saw that, there too, all my emails