ORA-06502: Long parameter
Hi all,
we´re using Oracle 9.2.0.4. We have a procedure with a long parameter.
When I execute this procedure with more than 32400 characters, the I got the following error:
ORA-06502: PL/SQL: numeric or value error: character string buffer too smallWha can I do to solve this?
thank you very much!!!!
[]´s
Hi,
I did this, but...
I got the error before the execute the first query.
When a decrease the size of string to 30000
characters I don't get any error.I don't know why it fails with the LONG datatype, but it is recommended to use CLOB instead of LONG.
Plus, the procedure call works, as expected, with CLOBs.
test@ora>
test@ora>
test@ora> --
test@ora> drop table tab_test;
Table dropped.
test@ora> drop procedure p_ins_tab_test;
Procedure dropped.
test@ora> drop sequence sq_tab_test;
Sequence dropped.
test@ora>
test@ora> --
test@ora> create sequence sq_tab_test;
Sequence created.
test@ora> create table tab_test (
2 id number(9) not null,
3 id_2 number(9) not null,
4 dt date not null,
5 data clob);
Table created.
test@ora>
test@ora> --
test@ora> create or replace
2 procedure p_ins_tab_test(
3 p_id_2 in tab_test.id_2%type,
4 p_data in tab_test.data%type)
5 is
6 begin
7 insert into tab_test (id,id_2,dt,data)
8 values (sq_tab_test.nextval, p_id_2, sysdate, p_data);
9 commit;
10 end p_ins_tab_test;
11 /
Procedure created.
test@ora>
test@ora> --
test@ora> declare
2 v_data clob;
3 n_len number;
4 begin
5 for i in 1..10 loop
6 v_data := v_data || dbms_random.string(1,4000);
7 end loop;
8 n_len := dbms_lob.getlength(v_data);
9 dbms_output.put_line('n_len = '||n_len);
10 --
11 p_ins_tab_test(100, v_data);
12 end;
13 /
n_len = 40000
PL/SQL procedure successfully completed.
test@ora>
test@ora> --
test@ora> select dbms_lob.getlength(data)
2 from tab_test
3 where id_2 = 100;
DBMS_LOB.GETLENGTH(DATA)
40000
test@ora>
test@ora>
test@ora>See the recommendation by Oracle, here -
http://download.oracle.com/docs/cd/B19306_01/server.102/b14220/datatype.htm#sthref3806
HTH
isotope
Similar Messages
-
ORA-06502 trying to load a long raw into a variable.
Hi. In my table "banco_imagem" the bim_src column is a long raw type.
I´m using oracle forms 6 (not 6i), so I can´t use blob type to save my images.
Now I´m trying to load the long raw column into a variable in a package that runs on 10g.
I´m trying to execute de folowing code at sql plus:
declare
wbim long raw;
begin
select bim_src into wbim from banco_imagem where rownum=1;
end;
The column is not null. It has a value.
I got the folowing error:
ORA-06502: PL/SQL: numeric or value error
ORA-06512: at line 4
My goal is to load this column to convert it to blob so I can manipulate with my others (already running) functions.
Can anyone help me?
Thanks!Hi Mcardia,
not sure where you're going wrong, but perhaps if you compare what you've done up to now to the following code snippet, you may figure it out eventually!
SQL> drop table test_raw
2 /
Table dropped.
SQL>
SQL> create table test_raw (col_a long raw, col_b blob)
2 /
Table created.
SQL> set serveroutput on
SQL> declare
2
3 l1 long raw;
4 l2 long raw;
5
6 b1 blob;
7
8 begin
9
10 l1:= utl_raw.cast_to_raw('This is a test');
11
12 insert into test_raw (col_a) values (l1);
13
14
15 select col_a
16 into l2
17 from test_raw
18 where rownum < 2;
19
20 dbms_lob.createtemporary (b1, false);
21
22 dbms_output.put_line(utl_raw.cast_to_varchar2(l2));
23 b1 := l2;
24
25 update test_raw set col_b = b1;
26
27 commit;
28
29 dbms_output.put_line('Done ');
30
31 exception
32 when others then
33 dbms_output.put_line('Error ' || sqlerrm);
34 end;
35 /
This is a test
Done
PL/SQL procedure successfully completed.Bear in mind that I'm running on the following:
BANNER
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
PL/SQL Release 10.2.0.4.0 - Production
CORE 10.2.0.4.0 Production
TNS for Solaris: Version 10.2.0.4.0 - Production
NLSRTL Version 10.2.0.4.0 - Production -
ORA-06502: error when inserting into table via db link with long datatype
Folks,
I am getting the following error:
ORA-06502: PL/SQL: numeric or value error: character string buffer too small.
This occurs when an insert is done via a database link into a table that has a LONG data type for one of the columns, and the string contains some carriage returns and or line feeds.
I have checked by removing the db link, and inserting into a local table with identical column data types, where there is no error.
So this might be another db link bug?
So I need to remove the carriage returns and/or line feeds
in my pl/sql block in the page process. I have tried
l_text := REPLACE(l_text, CHR(10), ' ');
l_text := REPLACE(l_text, CHR(13), NULL);
but still getting the ORA-06502. Would really appreciate some advice here, please.
Cheers
KIMScott,
Time to 'fess up':
My fault sorry, the error was coming from another page process where I had allowed insufficient string length for one of the variables, and my error message did not identify the page process clearly.
This leads me to make a request for future releases, could the system error messages state which page process caused the problem?
One other thing I notice, and this might be a feature not a fault, the page processes are numbered: "Page Process: 3 of 5". However process 3 is not the 3rd one to be processed, and probably refers to the order in which they are created. Should the number reflect the process order?
Cheers
KIM -
Ora-06502: variable length too long on report query xml schema download
on shared components/report queries/edit report query/
and downloading my queries in xml schema format (radio button).
Get
ORA-06502: PL/SQL: numeric or value error: raw variable length too long
when i click the download button.
EDIT:
i want to add that i recently changed several columns in the database from 150 to 3000 chars long.
Edited by: Manny Rodriguez on Oct 11, 2011 7:19 AM"4000 bytes is the ultimate maximum. you can say 4000 *characters* , but it'll always be limited to 4000 *bytes* . "
http://asktom.oracle.com/pls/apex/f?p=100:11:0::::P11_QUESTION_ID:1224836384599#201073000346459201\
"The maximum length of the column is determined by the national character set definition. Width specifications of character data type NVARCHAR2 refer to the number of characters. The maximum column size allowed is 4000 bytes."
http://docs.oracle.com/cd/E11882_01/server.112/e26088/sql_elements001.htm#SQLRF50976
By the way, you're treating your numbers as STRINGS, remove the quotes around your zero's. -
Error : ORA-06502: PL/SQL: numeric or value error while fetch LONG datatype
Hello All,
I have written a script to fetch the text for a view in PLSQL and it gives me the following error :
Error : ORA-06502: PL/SQL: numeric or value error
declare
l_text all_views.text%type;
begin
SELECT text INTO l_text FROM all_views WHERE view_name = 'XXVIEW';
exception
when others then
dbms_output.put_line('Error : '||sqlerrm);
end;
The above works for some views and not view other views. Can anyone let me know what could be the reason for ORA-06502 when fetching into a long variable in PLSQL.
Would appreciate any response.
Thanks,If view 'XXVIEW' contains "no record" for field "text" then it'll show this error.
I mean "SELECT text FROM all_views WHERE view_name = 'XXVIEW';" returns "No record found" then how can you assign "no record" to a variable "l_text ".
try to execute : SELECT text FROM all_views WHERE view_name = 'XXVIEW';
What does it give you? any "Blank records"?
Edited by: H. on Feb 20, 2009 8:17 AM -
ORA-06502: PL/SQL: numeric or value error: raw variable length too long
Hi All,
Oracle 9.2.0.1.0 and Oracle 10g.
I the following procedure:
CREATE OR REPLACE TYPE Resource_TT AS TABLE OF RAW(16)
CREATE OR REPLACE PROCEDURE GET_ROLEMAPPING_Temp
RoleIds IN NVARCHAR2 DEFAULT NULL ,
Application IN NVARCHAR2 DEFAULT NULL ,
MappingExixts OUT NVARCHAR2
AS
v_Application NVARCHAR2(150) := Application;
resource_list CONSTANT Resource_TT := Resource_TT(RoleIds);
v_temp NUMBER(1, 0) := 0;
BEGIN
SELECT 1 INTO v_temp
FROM DUAL
WHERE EXISTS ( SELECT SecurityGroupId
FROM SKESGResourceMapping
WHERE APPLICATION = v_Application
AND RoleId IN
select column_value
from table(resource_list)
EXCEPTION
WHEN NO_DATA_FOUND THEN
MappingExixts := 'NO';
END;
IF v_temp = 1 THEN
MappingExixts := 'YES';
END IF;
END;
while calling the procedure from sql*plus, the calling block is :
variable MappingExixts nvarchar2(100);
execute Get_RoleMapping_Temp('2f90e7969e0a9045aeb5b5ed7b3da9d6,363aef470e10094281e5040627e3b6f8', 'repo1', :MappingExixts);
print MappingExixts;
It is throwing an error saying:
ORA-06502: PL/SQL: numeric or value error: raw variable length too long
ORA-06512: at "ORACLE1.GET_ROLEMAPPING_TEMP", line 8
Thanks for your valuable time and suggestionsHi Binoy,
Thanks for your quick response, I increased its size to 200, but I am getting the following error
ORA-06502: PL/SQL: numeric or value error: hex to raw conversion error
ORA-06512: at "ORACLE1.GET_ROLEMAPPING_TEMP", line 8 -
ORA-06502 error with external table having long records
I'm getting a strange error with the oci driver that I don't get with the thin driver.
The basic situation is that we using external tables and both the oci and thin drivers have been working until we tested with a table that had longer records than the previous tables. The new table has 1800 byte records.
The thin driver still works fine with the new table. However, the oci driver generates the following error with the new table:
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
I suspect that with oci driver the oci DLLs are reading the external file and the DLLs can't handle the longer record length.
Particulars
- Oracle DB Server is 10.2.0.1 on SunOS 5.9
- OCI Instant Client instantclient_10_2 on Windows XP
- OCI client code from DB server installation running on DB server
- Works with thin driver from Windows XP and on DB server machine for all record lengths
- Works with both OCI drivers for records < 1800 bytes (don't know actual limit)
- Fails with both OCI drivers for records = 1800 bytes.
Does anyone out there have any thoughts.
Thanks in advance.Your access parameters are in the wrong order. External tables are a bit fussy like that. Refer to the access_parameters section in the Utilities manual and follow the order there. From memory it will go something like this:
RECORDS DELIMITED...
LOG/BAD/DISCARDFILE...
FIELDS TERMINATED...LDRTRIM
MISSING FIELD VALUES...
fields...
)Regards... -
I'm trying to write this out in chunks to a file, but I keep getting the following error;
ORA-06502: PL/SQL: numeric or value error: hex to raw conversion error
Not sure what is going on with this error. Never used RAW before and the error is at; dbms_lob.read(vxml,bytelen,vstart,my_vr);
I'm I missing anything in this code? Sorry for the long code, but was not sure if I could post it or not. Thanks!
CLOB is about 85m
vxml cLOB;
vstart NUMBER := 1;
bytelen NUMBER := 32000;
lenxml number;
my_vr RAW(32000);
l_output utl_file.file_type;
BEGIN
-- define output directory
l_output := utl_file.fopen('IO', p_month||'_'||p_day||'.wme','w', 32760);
vstart := 1;
bytelen := 32000;
-- get length of clob
SELECT dbms_lob.getlength(manual_cl)
INTO lenxml
FROM catalog
WHERE item_id = 3;
-- select clob into variable
SELECT manual_cl
INTO vxml
FROM catalog
WHERE item_id = 3;
vstart := 1;
WHILE vstart < lenxml and bytelen > 0
LOOP
>> dbms_lob.read(vxml,bytelen,vstart,my_vr); <<line producing error >>
utl_file.put(l_output,my_vr);
-- set the start position for the next cut
vstart := vstart + bytelen;
lenxml := lenxml - bytelen;
IF lenxml < 32000 THEN
bytelen := lenxml;
END IF;
end loop;
utl_file.fclose(l_output);
end;At the first look you are confusing dbms_lob.read procedures, which are overloaded with respect to different data types of parameter. It seems, you don't need raw variable at all, as you read a clob and write a character data into your file - simply change a data type of my_vr variable to varchar2(32000) - raw could be suitable if you would read a blob data and write it into binary file.
Best regards
Maxim -
UTL_SMTP , ORA-06502: PL/SQL: numeric or value error
Hi there,
I have a procedure that sends emails using UTL_SMTP. It is showing the "ORA-06502: PL/SQL: numeric or value error" whenever the message spans over the limit of the varchar2 type (32'767). I want to send in one email more than that limit, is there a way? any help?
Thanks in advancetry this procedure... it works to me!!
create or replace procedure po8.mail_files ( from_name varchar2,
to_name varchar2,
subject varchar2,
message varchar2,
max_size number default 9999999999,
filename1 varchar2 default null,
filename2 varchar2 default null,
filename3 varchar2 default null,
debug number default 0 ) is
This procedure uses the UTL_SMTP package to send an email message.
Up to three file names may be specified as attachments.
Parameters are:
1) from_name (varchar2)
2) to_name (varchar2)
3) subject (varchar2)
4) message (varchar2)
5) max_size (number)
5) filename1 (varchar2)
6) filename2 (varchar2)
7) filename3 (varchar2)
eg.
mail_files( from_name => 'oracle' ,
to_name => '[email protected]' ,
subject => 'A test',
message => 'A test message',
filename1 => '/data/oracle/dave_test1.txt',
filename2 => '/data/oracle/dave_test2.txt');
Most of the parameters are self-explanatory. "message" is a varchar2
parameter, up to 32767 bytes long which contains the text of the message
to be placed in the main body of the email.
filename{1,2,3} are the names of the files to be attached to the email.
The full pathname of each file must be specified. The files must exist
in one of the directories specified in the init.ora parameter
UTL_FILE_DIR. All filename parameters are optional: It is not necessary
to specify unused file parameters (eg. filename3 is missing in the above
example).
The max_size parameter enables you to place a constraint on the maximum
size of message, including all attachments, that the procedure will send.
If this limit is exceeded, the procedure will truncate the message at
that point with a '*** truncated ***' message. The default is effectively
unlimited. However, the text of message body is still limited to 32Kb, as
it is passed in as a varchar2.
Obviously, as with any Oracle procedure, the parameter values can (and
usually will be) PL/SQL variables, rather than hard-coded literals, as
shown here.
Written: Dave Wotton, 14/6/01 (Cambridge UK)
This script comes with no warranty or support. You are free to
modify it as you wish, but please retain an acknowledgement of
my original authorship.
Amended: Dave Wotton, 10/7/01
Now uses the utl_smtp.write_data() method to send the message,
eliminating the 32Kb message size constraint imposed by the
utl_smtp.data() procedure.
Amended: Dave Wotton, 20/7/01
Increased the v_line variable, which holds the file attachment
lines from 400 to 1000 bytes. This is the maximum supported
by RFC2821, The Simple Mail Transfer Protocol specification.
Amended: Dave Wotton, 24/7/01
Now inserts a blank line before each MIME boundary line. Some
mail-clients require this.
Amended: Dave Wotton, 4/10/01
Introduced a 'debug' parameter. Defaults to 0. If set to
non-zero then errors in opening files for attaching are
reported using dbms_output.put_line.
Include code to hand MS Windows style pathnames.
You may need to modify the following variable if you don't have a local
SMTP service running (particularly relevant to Windows 2000 servers).
Refer to http://home.clara.net/dwotton/dba/oracle_smtp.htm for more
details.
v_smtp_server varchar2(20) := 'doc148.xtec.es';
v_smtp_server_port number := 25;
v_directory_name varchar2(100);
v_file_name varchar2(100);
v_line varchar2(1000);
crlf varchar2(2):= chr(13) || chr(10);
mesg varchar2(32767);
conn UTL_SMTP.CONNECTION;
type varchar2_table is table of varchar2(200) index by binary_integer;
file_array varchar2_table;
i binary_integer;
v_file_handle utl_file.file_type;
v_slash_pos number;
mesg_len number;
mesg_too_long exception;
invalid_path exception;
mesg_length_exceeded boolean := false;
begin
-- first load the three filenames into an array for easier handling later ...
file_array(1) := filename1;
file_array(2) := filename2;
file_array(3) := filename3;
-- Open the SMTP connection ...
conn:= utl_smtp.open_connection( v_smtp_server, v_smtp_server_port );
-- Initial handshaking ...
utl_smtp.helo( conn, v_smtp_server );
utl_smtp.mail( conn, from_name );
utl_smtp.rcpt( conn, to_name );
utl_smtp.open_data ( conn );
-- build the start of the mail message ...
mesg:= 'Date: ' || TO_CHAR( SYSDATE, 'dd Mon yy hh24:mi:ss' ) || crlf ||
'From: ' || from_name || crlf ||
'Subject: ' || subject || crlf ||
'To: ' || to_name || crlf ||
'Mime-Version: 1.0' || crlf ||
'Content-Type: multipart/mixed; boundary="DMW.Boundary.605592468"' || crlf ||
'' || crlf ||
'This is a Mime message, which your current mail reader may not' || crlf ||
'understand. Parts of the message will appear as text. If the remainder' || crlf ||
'appears as random characters in the message body, instead of as' || crlf ||
'attachments, then you''ll have to extract these parts and decode them' || crlf ||
'manually.' || crlf ||
'' || crlf ||
'--DMW.Boundary.605592468' || crlf ||
'Content-Type: text/plain; name="message.txt"; charset=US-ASCII' || crlf ||
'Content-Disposition: inline; filename="message.txt"' || crlf ||
'Content-Transfer-Encoding: 7bit' || crlf ||
'' || crlf ||
message || crlf ;
mesg_len := length(mesg);
if mesg_len > max_size then
mesg_length_exceeded := true;
end if;
utl_smtp.write_data ( conn, mesg );
-- Append the files ...
for i in 1..3 loop
-- Exit if message length already exceeded ...
exit when mesg_length_exceeded;
-- If the filename has been supplied ...
if file_array(i) is not null then
begin
-- locate the final '/' or '\' in the pathname ...
v_slash_pos := instr(file_array(i), '/', -1 );
if v_slash_pos = 0 then
v_slash_pos := instr(file_array(i), '\', -1 );
end if;
-- separate the filename from the directory name ...
v_directory_name := substr(file_array(i), 1, v_slash_pos - 1 );
v_file_name := substr(file_array(i), v_slash_pos + 1 );
-- open the file ...
v_file_handle := utl_file.fopen(v_directory_name, v_file_name, 'r' );
-- generate the MIME boundary line ...
mesg := crlf || '--DMW.Boundary.605592468' || crlf ||
'Content-Type: application/octet-stream; name="' || v_file_name || '"' || crlf ||
'Content-Disposition: attachment; filename="' || v_file_name || '"' || crlf ||
'Content-Transfer-Encoding: 7bit' || crlf || crlf ;
mesg_len := mesg_len + length(mesg);
utl_smtp.write_data ( conn, mesg );
-- and append the file contents to the end of the message ...
loop
utl_file.get_line(v_file_handle, v_line);
if mesg_len + length(v_line) > max_size then
mesg := '*** truncated ***' || crlf;
utl_smtp.write_data ( conn, mesg );
mesg_length_exceeded := true;
raise mesg_too_long;
end if;
mesg := v_line || crlf;
utl_smtp.write_data ( conn, mesg );
mesg_len := mesg_len + length(mesg);
end loop;
exception
when utl_file.invalid_path then
if debug > 0 then
dbms_output.put_line('Error in opening attachment '||
file_array(i) );
end if;
-- All other exceptions are ignored ....
when others then
null;
end;
mesg := crlf;
utl_smtp.write_data ( conn, mesg );
-- close the file ...
utl_file.fclose(v_file_handle);
end if;
end loop;
-- append the final boundary line ...
mesg := crlf || '--DMW.Boundary.605592468--' || crlf;
utl_smtp.write_data ( conn, mesg );
-- and close the SMTP connection ...
utl_smtp.close_data( conn );
utl_smtp.quit( conn );
end;
NOT MINE BUT COPY PASTE TO HELP YOU... -
Import Export Error (ORA-06502)
All,
We are trying to migrate the code from windows 2000 HTMLDB 1.5.0.00.33 to solaris 9 HTMLDB 1.5.0.00.33 by using the export/import function. After migration, one report went wrong with the following message.
report error:
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
The tables definition are identical and there's no data in the production table. When we try to reduce the query length from 3000 to 2500 characters, the error message disappears on production.
Is there any HTMLDB global variable controls the maximum length of the report "region source"?
Any response would be appreciate.
Thanks,
Tony
===========================================
PS: Here's our query:
select
x.supreq_id,
DECODE(x.pk, null, 'Add new record:', ''||'<img src="#IMAGE_PREFIX#edit.gif" border="0" alt="Edit Icon">') edit,
x.pk,
x.request,
x.subject,
x.severity,
x.priority,
x.status,
x.request_type,
x.response,
x.username,
x.created_date,
x.note,
x.cks
from (
select
htmldb_item.hidden(1,supreq_id) supreq_id,
supreq_id edit,
supreq_id pk,
htmldb_item.text(3, request,'','','onFocus="javascript:window.status=this.value" onBlur="javascript:window.status=''Done''"') request,
htmldb_item.select_list_from_lov(4,subject,'REQUEST_SUBJECT','','NO') subject,
htmldb_item.select_list(5, severity, '3,2,1', 'style="width:40px"','NO') severity,
htmldb_item.select_list_from_lov(6,priority,'REQUEST_PRIORITY','','NO') priority,
htmldb_item.select_list_from_lov(7,status,'REQUEST_STATUS','','NO') status,
htmldb_item.select_list_from_lov(8, request_type, 'SUPPORT_REQUEST_TYPE','', 'NO') request_type,
htmldb_item.text(9, response,'','','onFocus=javascript:window.status=this.value;') response,
htmldb_item.select_list_from_lov(10, username, 'USER_EMPLOYEE', 'style="width:100px"','NO') username,
htmldb_item.date_popup(11, rownum,created_date, 'mm/dd/yyyy', 8) created_date,
htmldb_item.text(12, note,'','','onFocus=javascript:window.status=this.value;') note,
htmldb_item.md5_checksum(request, subject, severity, priority, status, request_type, response, username, created_date,note) cks
from
art_sup_requests
where
(:P319_PRIORITY IS NULL OR :P319_PRIORITY ='%' OR
INSTR(UPPER(ART_SUP_REQUESTS.PRIORITY),UPPER(:P319_PRIORITY)) > 0)
AND
(:P319_SEVERITY IS NULL OR :P319_SEVERITY ='%' OR
INSTR(UPPER(ART_SUP_REQUESTS.SEVERITY),UPPER(:P319_SEVERITY)) > 0)
AND
(:P319_SUBJECT IS NULL OR :P319_SUBJECT ='%' OR
INSTR(UPPER(ART_SUP_REQUESTS.SUBJECT),UPPER(:P319_SUBJECT)) > 0)
AND (:P319_CREATED_DATE IS NULL OR
TRUNC(ART_SUP_REQUESTS.CREATED_DATE)=TO_DATE(:P319_CREATED_DATE,'MM/DD/YYYY'))
AND (:P319_REQUEST_TYPE IS NULL OR :P319_REQUEST_TYPE ='%' OR
INSTR(UPPER(ART_SUP_REQUESTS.REQUEST_TYPE),UPPER(:P319_REQUEST_TYPE)) > 0)
AND (:P319_REQUEST IS NULL OR
INSTR(UPPER(ART_SUP_REQUESTS.REQUEST),UPPER(:P319_REQUEST)) > 0)
AND (:P319_USERNAME IS NULL OR :P319_USERNAME ='%' OR
INSTR(UPPER(ART_SUP_REQUESTS.USERNAME),UPPER(:P319_USERNAME)) > 0)
AND (:P319_ID IS NULL OR ART_SUP_REQUESTS.SUPREQ_ID = :P319_ID)
union all
select
htmldb_item.hidden(1,null) supreq_id,
null edit,
null pk,
htmldb_item.text(3, null) request,
htmldb_item.select_list_from_lov(4,null,'REQUEST_SUBJECT','','NO') subject,
htmldb_item.select_list(5, null, '3,2,1', 'style="width:40px"','NO') severity,
htmldb_item.select_list_from_lov(6,null,'REQUEST_PRIORITY','','NO') priority,
htmldb_item.select_list_from_lov(7,null,'REQUEST_STATUS','','NO') status,
htmldb_item.select_list_from_lov(8, null, 'SUPPORT_REQUEST_TYPE','', 'NO') request_type,
htmldb_item.text(9, null) response,
htmldb_item.select_list_from_lov(10, null,
'USER_EMPLOYEE','style="width:100px"','NO') username,
htmldb_item.date_popup(11, null, sysdate,'mm/dd/yyyy', 8) created_date,
htmldb_item.text(12, null) note,
htmldb_item.md5_checksum(null,null, null, null, null, null, null, null, null, null) cks
from dual) xScott,
Thanks for the response. We've applied HTMLDB version 1.5.1.00.12 on both develop and production servers yesterday but the ORA-06502 error still persist. We've also tried to use package and "pl/sql return sql" instead of a long sql query but received the same result.
The solaris instance is using "Western European ISO-8859-1" as the file character set and the windows is using "Western European Windows 1252". Is there any easy way to change the DAD character set on the production box?
Thanks,
Tony -
I'm attempting to dynamically generate a rather large SQL query via the "PL/SQL function body returning SQL query" report region option. The SQL query generated will possibly be over 32K. When I execute my page, I sometimes receive the "ORA-06502: PL/SQL: numeric or value error" which points to a larger than 32K query that was generated. I've seen other posts in the forum related to this dynamic SQL size limitation issue, but they are older (pre-2010) and point to the 32K limit of the DNS (EXECUTE IMMEDIATE) and DBMS_SQL. I found this post (dynamic sql enhancements in 11g) which discusses 11g no longer having the 32K size limitation for generating dynamic SQL. Our environment is on 11gR2 and using ApEx 4.2.1. I do not know which dynamic SQL method -- DNS or DBMS_SQL -- ApEx 4.2.1 is using. Can someone clarify for me which dynamic SQL method ApEx uses to implement the "PL/SQL function body returning SQL query" option?
As a test, I created a page on apex.oracle.com with a report region with the following source:
declare
l_stub varchar2(25) := 'select * from sys.dual ';
l_sql clob := l_stub || 'union all ';
br number(3) := 33;
begin
while length ( l_sql ) < 34000 loop
l_sql := l_sql || l_stub || 'union all ';
end loop;
l_sql := l_sql || l_stub;
for i in 1 .. ceil ( length ( l_sql ) / br ) loop
dbms_output.put_line ( dbms_lob.substr ( l_sql, br, ( ( i - 1 ) * br ) + 1 ) );
end loop;
return l_sql;
end;
The dbms_output section is there to be able to run this code in SQL*Plus and confirm the size of the SQL is indeed larger than 32K. When running this in SQL*Plus, the procedure is successful and produces a proper SQL statement which can be executed. When I put this into the report region on apex.oracle.com, I get the ORA-06502 error.
I can certainly implement a work-around for my issue by creating a 'Before Header' process on the page which populates an ApEx collection with the data I am returning and then the report can simply select from the collection, but according to documentation, the above 32K limitation should be resolved in 11g. Thoughts?
Shane.What setting do you use in your report properties - especially in Type and in Region Source?
If you have Type="SQL Query", then you should have a SELECT statement in the Region Source. Something like: SELECT .... FROM ... WHERE
According to the ERR-1101 error message, you have probably set Type to "SQL Query (PL/SQL function body returning SQL query)". In this situation APEX expects you to write a body of a PL/SQL function, that will generate the text of a SQL query that APEX should run. So it can be something like:
declare
mycond varchar2(4000);
begin
if :P1_REPORT_SEARCH is not null THEN
mycond:='WHERE LAST_NAME like :P1_REPORT_SEARCH ||''%''';
end if;
return 'select EMPLOYEE_ID, FIRST_NAME, LAST_NAME from EMPLOYEES ' ||mycond;
end;
And for escaping - are you interested in escaping the LIKE wildcards, or the quotes?
For escaping the wildcards in LIKE function so that when the user enters % you will find a record with % and not all functions, look into the SQL Reference:
http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14200/conditions007.htm
(You would than need to change the code of your function accordingly).
If you are interested in escaping the quotes, try to avoid concatenating the values entered by the user into the SQL. If you can, use bind variables instead - as I have in my example above. If you start concatenating the values into the text of SQL, you are open to SQLInjection - user can enter anything, even things that will break your SQL. If you really need to allow users to choose the operator, I would probably give them a separate combo for operators and a textfield for values, than you could check if the operator is one of the allowed ones and create the condition accordingly - and than still use bind variable for inserting the filtering value into the query. -
Package Returning Error ORA-06502: PL/SQL: numeric or value error
Hi,
I create a package to export to spread sheet .xls, The package work for simple query if i pass the query to package.
There is no error in package please create the package and do the following as mentioned below
create or replace
PACKAGE export_pkg_spread_sheet
AS
procedure download_excel(vsql in clob );
PROCEDURE excel_header(p_header in out nocopy clob);
procedure excel_content(p_content in out nocopy clob,
vsql in clob );
procedure excel_footer(p_footer in out nocopy clob);
procedure get_usable_sql (p_sql_in IN clob,
p_sql_out OUT clob);
END export_pkg_spread_sheet;
create or replace
PACKAGE body export_pkg_spread_sheet
AS
PROCEDURE excel_header (p_header IN OUT nocopy CLOB)
AS
BEGIN
p_header := '<html><body>';
END;
procedure download_excel( vsql in clob )
as
p_header clob;
p_footer clob;
p_content clob;
begin
owa_util.mime_header( 'application/octet', FALSE );
htp.p('Content-Disposition: attachment; filename="report.xls"');
owa_util.http_header_close;
excel_header( p_header);
excel_content(p_content,vsql);
excel_footer(p_footer);
dbms_output.put_line(p_header ||p_content|| p_footer);
HTP.PRN( p_header ||p_content|| p_footer);
htmldb_application.g_unrecoverable_error := true;
end;
procedure excel_content(p_content in out nocopy clob,
vsql in clob)
as
p_sql_stmt clob;
cur PLS_INTEGER := DBMS_SQL.OPEN_CURSOR;
cols DBMS_SQL.DESC_TAB;
ncols PLS_INTEGER;
TYPE varColumn IS TABLE OF varchar2(32000);
vtab varColumn;
v_column_count NUMBER DEFAULT 0;
v_status INTEGER;
BEGIN
htp.prn('am here');
/* SELECT region_source into p_sql_stmt
FROM apex_application_page_regions
WHERE region_id = p_region_id AND
page_id = p_page_id AND
application_id = p_app_id; */
get_usable_sql (vsql,p_sql_stmt);
p_content := p_sql_stmt;
-- Parse the query.
DBMS_SQL.PARSE(cur, p_sql_stmt , DBMS_SQL.NATIVE);
-- Retrieve column information
DBMS_SQL.DESCRIBE_COLUMNS (cur, ncols, cols);
-- Display each of the column names
p_content := '<table> <tr>';
FOR colind IN 1 .. ncols
LOOP
p_content := p_content || '<td>' || cols(colind).col_name || '</td>';
END LOOP;
p_content := p_content || '</tr>';
vtab := varColumn(null);
for i in 1..ncols
loop
vtab.extend;
DBMS_SQL.DEFINE_COLUMN (cur, i, vtab(i), 2000);
--dbms_output.put_line(vtab(i));
end loop;
v_status := DBMS_SQL.EXECUTE (cur);
LOOP
p_content := p_content || '<tr>';
EXIT WHEN (DBMS_SQL.FETCH_ROWS (cur) <= 0);
FOR i IN 1 ..ncols
loop
DBMS_SQL.COLUMN_VALUE (cur, i, vtab(i));
-- p_content := p_content || '<td>' || 'xyz' || '</td>';
p_content := p_content || '<td>' || vtab(i) || '</td>';
END LOOP;
p_content := p_content || '</tr>' ;
END LOOP;
p_content := p_content || '<table>' ;
DBMS_SQL.CLOSE_CURSOR (cur);
exception
when others then
p_content := '<td>Exception Error in printing data</td><table>' ;
DBMS_SQL.CLOSE_CURSOR (cur);
end;
procedure excel_footer( p_footer in out nocopy clob)
as
begin
p_footer := '</body></html>';
end;
PROCEDURE get_usable_sql (p_sql_in IN clob, p_sql_out OUT clob)
IS
v_sql clob;
v_names DBMS_SQL.varchar2_table;
v_pos NUMBER;
v_length NUMBER;
v_exit NUMBER;
BEGIN
v_sql := p_sql_in;
v_names := wwv_flow_utilities.get_binds (v_sql);
FOR i IN 1 .. v_names.COUNT
LOOP
<<do_it_again>>
v_pos := INSTR (LOWER (v_sql), LOWER (v_names (i)));
v_length := LENGTH (LOWER (v_names (i)));
v_sql :=
SUBSTR (v_sql, 1, v_pos - 1)
|| v_names (i)
|| SUBSTR (v_sql, v_pos + v_length);
v_sql :=
REPLACE (v_sql,
UPPER (v_names (i)),
'(SELECT v('''
|| LTRIM (v_names (i), ':')
|| ''') FROM DUAL)'
IF INSTR (LOWER (v_sql), LOWER (v_names (i))) > 0
THEN
GOTO do_it_again;
END IF;
END LOOP;
p_sql_out := v_sql;
END;
END export_pkg_spread_sheet;
After creating the package pass the parameter to package like this
begin
export_pkg_spread_sheet.download_excel('select * from emp');
end;
Package will allow to download the spread shreet. If i try to pass the a complex query to package it is returning error as mentioned below
ORA-06502: PL/SQL: numeric or value error
In the above package there is a procedure called procedure excel_content which actuall prints the data in the spread sheet this is where the error is coming from there is a variable called vsql have declared it as clob to hold large string but still i am getting the same error when trying to pass a big string.
Please check the error and let me know.
Thanks
SudhirHi Praveen,
This is the query i am using to pass
Declare
qry clob;
Begin
qry := ' 'SELECT
AR.REGION_CODE,
AR.DISTRICT_CODE,
AR.TERRITORY_CODE,
CASE
WHEN AR.REGION_NAME IS NOT NULL AND AR.DISTRICT_NAME IS NULL AND AR.TERRITORY_NAME IS NULL THEN
AR.REGION_NAME
WHEN AR.REGION_NAME IS NOT NULL AND AR.DISTRICT_NAME IS NOT NULL AND AR.TERRITORY_NAME IS NULL THEN
AR.DISTRICT_NAME
WHEN AR.REGION_NAME IS NOT NULL AND AR.DISTRICT_NAME IS NOT NULL AND AR.TERRITORY_NAME IS NOT NULL THEN
AR.TERRITORY_NAME
END TERR_NAME,
AR.EMPLOYEE_ID,
AR.LAST_NAME,
AR.FIRST_NAME,
AR.GENDER,
AR.DATE_OF_HIRE,
AR.PROJECT_EMPLOYEE_TITLE_ID,
AR.COMPANY_ID,
AR.CUSTOMER_EMAIL,
AR.BUSINESS_EMAIL,
AR.CUSTOMER_VOICEMAIL,
AR.CUSTOMER_VOICEMAIL_EXT,
AR.QUINTILES_VOICEMAIL,
AR.QUINTILES_VOICEMAIL_EXT , complete_roster_pkg_report.AR_F_ADDRESS_GET_LINE_1(AR.PROJECT_ID,AR.EMPLOYEE_ID,1 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Shipping_ADDRESS_TYPE_1" , complete_roster_pkg_report.AR_F_ADDRESS_GET_LINE_2(AR.PROJECT_ID,AR.EMPLOYEE_ID,1 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Shipping_ADDRESS_TYPE_2" , complete_roster_pkg_report.AR_F_ADDRESS_GET_PHONE(AR.PROJECT_ID,AR.EMPLOYEE_ID,1 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Shipping_Phone" , complete_roster_pkg_report.AR_F_ADDRESS_GET_CITY_TOWN(AR.PROJECT_ID,AR.EMPLOYEE_ID,1 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Shipping_City_Town" , complete_roster_pkg_report.AR_F_ADDRESS_GET_COUNTRY_NAME(AR.PROJECT_ID,AR.EMPLOYEE_ID,1 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Shipping_Country_Name" , complete_roster_pkg_report.AR_F_ADDRESS_GET_STATE_NAME(AR.PROJECT_ID,AR.EMPLOYEE_ID,1 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Shipping_State_Name" , complete_roster_pkg_report.AR_F_ADDRESS_GET_ZIP_POSTAL(AR.PROJECT_ID,AR.EMPLOYEE_ID,1 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Shipping_ZipCode" , complete_roster_pkg_report.AR_F_ADDRESS_GET_LINE_1(AR.PROJECT_ID,AR.EMPLOYEE_ID,3 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Storage_ADDRESS_TYPE_1" , complete_roster_pkg_report.AR_F_ADDRESS_GET_LINE_2(AR.PROJECT_ID,AR.EMPLOYEE_ID,3 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Storage_ADDRESS_TYPE_2" , complete_roster_pkg_report.AR_F_ADDRESS_GET_PHONE(AR.PROJECT_ID,AR.EMPLOYEE_ID,3 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Storage_Phone" , complete_roster_pkg_report.AR_F_ADDRESS_GET_CITY_TOWN(AR.PROJECT_ID,AR.EMPLOYEE_ID,3 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Storage_City_Town" , complete_roster_pkg_report.AR_F_ADDRESS_GET_COUNTRY_NAME(AR.PROJECT_ID,AR.EMPLOYEE_ID,3 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Storage_Country_Name" , complete_roster_pkg_report.AR_F_ADDRESS_GET_STATE_NAME(AR.PROJECT_ID,AR.EMPLOYEE_ID,3 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Storage_State_Name" , complete_roster_pkg_report.AR_F_ADDRESS_GET_ZIP_POSTAL(AR.PROJECT_ID,AR.EMPLOYEE_ID,3 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Storage_ZipCode" , complete_roster_pkg_report.AR_F_ADDRESS_GET_LINE_1(AR.PROJECT_ID,AR.EMPLOYEE_ID,4 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Home_ADDRESS_TYPE_1" , complete_roster_pkg_report.AR_F_ADDRESS_GET_LINE_2(AR.PROJECT_ID,AR.EMPLOYEE_ID,4 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Home_ADDRESS_TYPE_2" , complete_roster_pkg_report.AR_F_ADDRESS_GET_PHONE(AR.PROJECT_ID,AR.EMPLOYEE_ID,4 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Home_Phone" , complete_roster_pkg_report.AR_F_ADDRESS_GET_CITY_TOWN(AR.PROJECT_ID,AR.EMPLOYEE_ID,4 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Home_City_Town" , complete_roster_pkg_report.AR_F_ADDRESS_GET_COUNTRY_NAME(AR.PROJECT_ID,AR.EMPLOYEE_ID,4 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Home_Country_Name" , complete_roster_pkg_report.AR_F_ADDRESS_GET_STATE_NAME(AR.PROJECT_ID,AR.EMPLOYEE_ID,4 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Home_State_Name" , complete_roster_pkg_report.AR_F_ADDRESS_GET_ZIP_POSTAL(AR.PROJECT_ID,AR.EMPLOYEE_ID,4 ,TO_DATE(AAH.EFFECTIVE_DATE)) "Home_ZipCode" FROM AR_V_ROSTER AR
LEFT JOIN AR_V_ADDRESS_HISTORY AAH
ON
(AR.PROJECT_ID = AAH.PROJECT_ID AND
AR.EMPLOYEE_ID = AAH.EMPLOYEE_ID)
WHERE
UPPER(AR.USER_EMPLOYEE_ID) = ''Q766730'' AND
AR.PROJECT_ID = 81 ';
export_pkg_spread_sheet.download_excel(qry);
End;
Praveen you can pass your DB table query to check the error. I am trying to pass as mentioned above.
Please let me know if my question is not clear.
Thanks
Sudhir -
ORA-06502 Error When Calling Function
Hi,
We have upgraded Oracle Database Server 9i to 11.1.0.7 and we are now using ODP.NET version 2.112.2.0 instead of 9.2.0.4 dll.
After the migration, we encountered ORA-06502 problem when we are calling a function from .NET application. We investigated and found that we have to set the parameter size for the return value parameter (varchar2). But there is a strange case that how do we guess the return value size, it can be 5 characters or 5.000 characters. Before 11g Oracle.DataAccess, we do not have that such problem. We were setting the parameter size 225 by default, but ODP.NET was returning 500 characters without any error.
The question is that how do we guess or know the actual parameter size when we are passing a Return Value parameter to the function?
Or is there a solution for this behaviour of ODP.NET?
Thanks.Is there a reason you can not set it to the default maximum size for a varchar2 of 32k?
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Oracle.DataAccess.Client;
using System.Data;
namespace test_function2
class Program
static void Main(string[] args)
OracleConnection con = new OracleConnection("Data Source=UTF8;User ID=scott;Password=tiger");
OracleCommand cmd = new OracleCommand("test_return", con);
cmd.CommandType = CommandType.StoredProcedure;
OracleParameter test_return = new OracleParameter("test_return", OracleDbType.Varchar2, 32000);
test_return.Direction = ParameterDirection.ReturnValue;
cmd.Parameters.Add(test_return);
OracleParameter test_input = new OracleParameter("test_input", OracleDbType.Varchar2);
test_input.Direction = ParameterDirection.Input;
test_input.Value = "blah";
cmd.Parameters.Add(test_input);
try
con.Open();
cmd.ExecuteNonQuery();
con.Close();
Console.WriteLine("{0}", test_return.Value);
Console.WriteLine("Press Enter to Continue");
Console.ReadLine();
catch (OracleException e)
Console.WriteLine(e.Number);
Console.WriteLine(e.Message);
Console.WriteLine("test failed\nPress Enter to Continue");
Console.ReadLine();
create or replace function test_return(in_var in varchar2)
return varchar2 is
begin
return lpad(in_var, 4000, 'TEST test') || lpad(in_var, 4000, 'DONE done');
end test_return;
/ -
ORA-06502 - Error when running "Ask The Expert 0.9"
Hi ,
I successfully installed "Ask the Expert" package with Apex 3.0 on Oracle 10g Database 10.2.0.1.0. No error ocurred during the import in my Apex environment.
Besides that, i'm having problems when i tried to run the "Aks the Expert". It always shows the following message errors:
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
Error Unable to write activity log.
I think it was a problem with APEX instalation, but i could run the Sample Application of Apex without any problem.
I opened an SR in Metalink, but to my surprise, the analist of support don't know what's wrong with the demo "Ask de Expert".
The debug function of the application show the following commands before the error ocurrs:
0.01:
0.01: S H O W: application="103" page="1" workspace="" request="" session="6648566035252817"
0.01: Language derived from: FLOW_PRIMARY_LANGUAGE, current browser language: en-us
0.01: alter session set nls_language="AMERICAN"
0.01: alter session set nls_territory="AMERICA"
0.01: NLS: CSV charset=WE8MSWIN1252
0.01: ...NLS: Set Decimal separator="."
0.01: ...NLS: Set NLS Group separator=","
0.02: ...NLS: Set date format="DD-MON-RR"
0.02: ...Setting session time_zone to -03:00
0.02: NLS: Language=en-us
0.02: Application 103, Authentication: CUSTOM2, Page Template: 667896385843019243
0.02: ...Determine if user "N3COUTINHO" workspace "951808960237899" can develop application "103" in workspace "951808960237899"
0.02: ...ok to reuse builder session for user:nobody
0.03: ...Application session: 6648566035252817, user=nobody
0.03: ...Determine if user "N3COUTINHO" workspace "951808960237899" can develop application "103" in workspace "951808960237899"
0.03: Session: Fetch session header information
0.03: ...Metadata: Fetch page attributes for application 103, page 1
0.03: Fetch session state from database
0.03: Branch point: BEFORE_HEADER
0.03: Fetch application meta data
0.04: Computation point: BEFORE_HEADER
0.04: ...Perform computation of item: P1_CLEAN_CRITERIA, type=FUNCTION_BODY
0.04: ...Performing function body computation
0.06: ...Session State: Save "P1_CLEAN_CRITERIA" - saving same value: ""
0.06: Processing point: BEFORE_HEADER
0.06: ...Process "Read and Write Activity Cookie": PLSQL (BEFORE_HEADER) declare l_cookie_id number; begin owa_util.mime_header('text/html', FALSE); -- ate_api.read_activity_cookie; l_cookie_id := ate_api.fetch_activity_cookie_val( 'COOKIE_ID' ); -- if l_cookie_id is null then l_cookie_id :=
Content-type: text/html; charset=ISO-8859-1 Set-Cookie: activity_ask_expert=1|2400346189796; expires=Wed, 01-Jan-2020 08:00:00 GMT; path=/;
0.06: Encountered unhandled exception in process type PLSQL
0.06: Show ERROR page...
0.06: Performing rollback...
Please, could any one help me to solve this problem ? Metalink couldn't help me diagnosing what's wrong.
Thanks,
Sergio CoutinhoHi,
I don´t know if it help the analisis, but i collect some informations about my environment:
1) HTML DB version
3.0.1
2) Database version
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options
3) Database server operating system (as well, if 32-bit or 64-bit)
Solaris 5.9 - 64 bits
4) Database Parameters:
PARAMETER VALUE
NLS_CALENDAR GREGORIAN
NLS_CHARACTERSET WE8ISO8859P1
NLS_COMP BINARY
NLS_CURRENCY $
NLS_DATE_FORMAT DD-MON-RR
NLS_DATE_LANGUAGE AMERICAN
NLS_DUAL_CURRENCY $
NLS_ISO_CURRENCY AMERICA
NLS_LANGUAGE AMERICAN
NLS_LENGTH_SEMANTICS BYTE
NLS_NCHAR_CHARACTERSET AL16UTF16
NLS_NCHAR_CONV_EXCP FALSE
NLS_NUMERIC_CHARACTERS .,
NLS_RDBMS_VERSION 10.2.0.1.0
NLS_SORT BINARY
NLS_TERRITORY AMERICA
NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM
NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR
NLS_TIME_FORMAT HH.MI.SSXFF AM
NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR
Could it explain why ASK THE EXPERT is running on hosted apex site and it´s
generating error when running in my environment?
Thanks for the help !
Sergio -
ORA-06502: PL/SQL: numeric or value error While Exporting in Oracle 10g
Connected to: Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Production
With the Partitioning, OLAP and Data Mining options
Export done in AR8MSWIN1256 character set and AL16UTF16 NCHAR character set
server uses AR8ISO8859P6 character set (possible charset conversion)
About to export the entire database ...
. exporting tablespace definitions
. exporting profiles
. exporting user definitions
. exporting roles
. exporting resource costs
. exporting rollback segment definitions
. exporting database links
. exporting sequence numbers
. exporting directory aliases
. exporting context namespaces
. exporting foreign function library names
. exporting PUBLIC type synonyms
. exporting private type synonyms
. exporting object type definitions
. exporting system procedural objects and actions
. exporting pre-schema procedural objects and actions
. exporting cluster definitions
. about to export SYSTEM's tables via Conventional Path ...
. . exporting table DEF$_AQCALL 0 rows exported
. . exporting table SRC_RQST_SEQ 1 rows exported
EXP-00091: Exporting questionable statistics.
. . exporting table SRC_USERS 6 rows exported
EXP-00091: Exporting questionable statistics.
. . exporting table SRC_YEAR_LOOKUP 40 rows exported
EXP-00091: Exporting questionable statistics.
. . exporting table TENDER_DETAIL_TABLE 36 rows exported
EXP-00091: Exporting questionable statistics.
. . exporting table TENDER_MASTER_TABLE 34 rows exported
EXP-00091: Exporting questionable statistics.
. . exporting table TENDER_NEW_DETAIL_TABLE 4 rows exported
EXP-00091: Exporting questionable statistics.
. exporting synonyms
. exporting views
EXP-00056: ORACLE error 6502 encountered
ORA-06502: PL/SQL: numeric or value error
LPX-00210: expected '<' instead of 'n'
ORA-06512: at "SYS.UTL_XML", line 152
ORA-06512: at "SYS.DBMS_METADATA_INT", line 7195
ORA-06512: at "SYS.DBMS_METADATA_INT", line 9135
ORA-06512: at "SYS.DBMS_METADATA", line 1882
ORA-06512: at "SYS.DBMS_METADATA", line 3707
ORA-06512: at "SYS.DBMS_METADATA", line 3689
ORA-06512: at line 1
EXP-00056: ORACLE error 6502 encountered
ORA-06502: PL/SQL: numeric or value error
LPX-00210: expected '<' instead of 'n'
ORA-06512: at "SYS.UTL_XML", line 152
ORA-06512: at "SYS.DBMS_METADATA_INT", line 7195
ORA-06512: at "SYS.DBMS_METADATA_INT", line 9135
ORA-06512: at "SYS.DBMS_METADATA", line 1882
ORA-06512: at "SYS.DBMS_METADATA", line 3707
ORA-06512: at "SYS.DBMS_METADATA", line 3689
ORA-06512: at line 1
EXP-00000: Export terminated unsuccessfully
Plz reply me the appropriate Solution
Edited by: user8920919 on May 3, 2010 12:27 AMhi,
EXP-00091: Exporting questionable statistics The client character set(NLS_LANG) does not match the server character;
select parameter,value from nls_database_parameters where parameter like '%CHARACTERSET%';
and check the client system character set
- Pavan Kumar N
- ORACLE OCP - 9i/10g
https://www.oracleinternals.blogspot.com
Maybe you are looking for
-
My ipad no longer connects to app market
Upon every attempt I get a pop up that states "unable to connect to AppStore " or "unable to connect to iTunes" This is as frustrating as Windows!
-
How to play Youtube on my W995??
How to play youtube application on W995? It keep on buffering, but failed at last!
-
A question using the setString to pass parameter
Hello, there: part of my SQL statement is like this: p_table.user_id in (?) In my JDBC code, I wrote String str = "usr1"; ps.setString(1, str) to pass the parameter to the SQL statement - it works fine; However, if I wrote (in order to select from mu
-
Where is the FCPX 10.1.4 update?
I was notified by apple that an update was available but i can't find it? where is the final cut pro x 10.1.4 update?
-
Java Heap Size Recommendation Request
Looking for suggestions on tuning. Running CF10 update 13 on a 64 bit server with 8 GB RAM, running into memory issues (I suspect). JVM is only set to 256 / 512 right now, so I'm going to increase it. CF and a handful of sites is pretty much all this