Numeric or value error when submitting form
I have a form based of a stored procedure. The form has about 20 fields on it. For some reason the form only allows data entry on only about 10 of them. If I put data in any of the other 10, I get: "An unexpected error occurred: ORA-06502: PL/SQL: numeric or value error (WWV-16016)"
I have looked everywhere to see what's going on. I checked the procedure to make sure its parameters are good. It takes takes all VARCHAR2's, so thats OK. I checked the fields in the form editor for validation, and none are being validated, so thats OK. I made sure all the fields are updatable and they are. I even checked the table to make sure that the data can go into the fields, even though I know that the error returned there would be through the procedure, not Portal. I am stumped. What am I missing?
Rich
Follow Up: While troubleshooting this, I filled in all the fields with one character each and the form submitted. I added characters little by little to each field until I got the error. It seems like Portal has a problem when I pass X amount of characters from a form. I say "Portal" because I thought this might be an OS parameter, but I get the same error in both Win2000 and Solaris.
Any ideas where this setting is? Or how to change it?
Rich
Similar Messages
-
Symbol error when submitting form
experiencing a symbol error when submitting form.
Hi Gen,
Unfortunately, the error came from a client who was submitting a form via Mac OS. He stated that when he attempted to submit he received a symbol error.
On another note, I did experience issues with periods (.) within another form such as 2009.01 and 2011.25. When I downloaded the files corresponding to the numbers, it wouldn’t allow me to save it with the period (used an underscore instead).
Warmest regards,
Delia
Delia Boyd
Program Manager, Standards Development
Executive Office
AOAC INTERNATIONAL
481 N. Frederick Avenue, Suite 500
Gaithersburg, MD 20877-2417
301-924-7077 x126
301-924-7089 - Fax
[email protected]<mailto:[email protected]>
www.aoac.org<http://www.aoac.org/>
cid:[email protected]
127th AOAC Annual Meeting & Exposition
Palmer House Hilton
Chicago, Illinois
August 25-28, 2013
For more information visit our website
at: http://www.aoac.org/meetings1/127th_annual_mtg/main_2.htm
þ Please consider the environment before printing this email.
...you will see it when you believe it! -
-6502 ORA-06502: PL/SQL: numeric or value error when using 'Create CAPI Definition'
I get an error when I try to create a CAPI definition with Headstart untilities (6i). I use HSU_CAPI revision 6.5.2.0
The detailed information says the following:
Message
BLAPI.OPEN_ACTIVITY
Start HSU_CAPI.run
Number of Tables to create CAPI for 1
Initial checks for table KCS_TENDERS with id 692754610572409851363604771392473242
HSU_CAPT.initial_checks for table KCS_TENDERS
HSU_CAPF.initial_checks for table KCS_TENDERS
HSU_CAPC.initial_checks Custom Services for table KCS_TENDERS
HSU_CAPB.initial_checks BRDD for table KCS_TENDERS
bltext.get_lines_from_repository, p_text_type=CDINOT
bltext.get_line_containing
bltext.get_line_containing
bltext.get_lines_from_repository, p_text_type=CDIPLS
bltext.get_line_containing
bltext.get_line_containing
bltext.get_line_containing
bltext.get_line_containing
bltext.get_line_containing
bltext.get_line_containing
KCS_TENDERS Business Rule Design Definition BR_TNR001_CEV does not have any Trigger Columns. Rule will fire when any column is updated.
bltext.get_lines_from_repository, p_text_type=CDINOT
bltext.get_line_containing
bltext.get_line_containing
bltext.get_lines_from_repository, p_text_type=CDIPLS
bltext.get_line_containing
bltext.get_line_containing
bltext.get_line_containing
bltext.get_line_containing
bltext.get_line_containing
bltext.get_line_containing
Creating CAPI for table KCS_TENDERS with id 692754610572409851363604771392473242
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Pre-Before-Insert-stmt, Open transaction.
Write Text for element type APPLOG with id 753236628580304413262318236391196826 - Text type: ALCODE number of text lines = 6 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580304413262318236391196826 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Pre-Before-Update-stmt, Open transaction.
Write Text for element type APPLOG with id 753236628580332747461215454262479002 - Text type: ALCODE number of text lines = 6 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580332747461215454262479002 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Pre-Before-Delete-stmt, Open transaction.
Write Text for element type APPLOG with id 753236628580361081660112672133761178 - Text type: ALCODE number of text lines = 6 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580361081660112672133761178 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Post-After-Insert-stmt, Close transaction.
Write Text for element type APPLOG with id 753236628580389415859009890005043354 - Text type: ALCODE number of text lines = 6 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580389415859009890005043354 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Post-After-Update-stmt, Close transaction.
Write Text for element type APPLOG with id 753236628580417750057907107876325530 - Text type: ALCODE number of text lines = 6 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580417750057907107876325530 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Post-After-Delete-stmt, Close transaction.
Write Text for element type APPLOG with id 753236628580446084256804325747607706 - Text type: ALCODE number of text lines = 6 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580446084256804325747607706 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Pre-Before-Delete-row, Save old data.
Write Text for element type APPLOG with id 753236628580474418455701543618889882 - Text type: ALCODE number of text lines = 404 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580474418455701543618889882 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Pre-Insert, Call CAPI.
Write Text for element type APPLOG with id 753236628580568865785358936523163802 - Text type: ALCODE number of text lines = 4 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580568865785358936523163802 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Pre-Update, Call CAPI.
Write Text for element type APPLOG with id 753236628580597199984256154394445978 - Text type: ALCODE number of text lines = 4 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580597199984256154394445978 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Pre-Delete, Call CAPI.
Write Text for element type APPLOG with id 753236628580625534183153372265728154 - Text type: ALCODE number of text lines = 17 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580625534183153372265728154 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Post-Insert, Call CAPI.
Write Text for element type APPLOG with id 753236628580653868382050590137010330 - Text type: ALCODE number of text lines = 7 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580653868382050590137010330 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Post-Update, Call CAPI.
Write Text for element type APPLOG with id 753236628580682202580947808008292506 - Text type: ALCODE number of text lines = 144 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580682202580947808008292506 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
Recreating KCS_TENDERS Table API/Trigger Logic - Event: Post-Delete, Call CAPI.
Write Text for element type APPLOG with id 753236628580767205177639461622139034 - Text type: ALCODE number of text lines = 282 - REPLACE
Deleted old text
Write Text for element type APPLOG with id 753236628580767205177639461622139034 - Text type: ALCMNT number of text lines = 1 - REPLACE
Deleted old text
HSU_CAPF.create_or_find_capi_pack
hsu_capi.find_plm (kcs_tnr_capi, 692754610572409851363604771392473242, CAPI).
capi package found in the context folder
BLPLM.UPD
FREE_FORMAT_TEXT_FLAG......... = Y
IMPLEMENTATION_NAME........... = kcs_tnr_capi
PLSQL_MODULE_TYPE............. = PACKAGE
SCOPE......................... = PUBLIC
COMPLETION_STATUS............. = COMPLETED
NAME.......................... = kcs_tnr_capi
PURPOSE....................... = Custom API package for implementing Business Rules and supporting TAPI
Recreated Package KCS/ KCS_TNR_CAPI, preserving only the Revision History.
HSU_CAPF.add_tags_er_av
bltext.get_lines_from_repository, p_text_type=CDINOT
bltext.get_line_containing
bltext.get_line_containing
bltext.get_lines_from_repository, p_text_type=CDINOT
bltext.get_line_containing
bltext.get_line_containing
bltext.get_lines_from_repository, p_text_type=CDINOT
bltext.get_line_containing
bltext.get_line_containing
bltext.get_lines_from_repository, p_text_type=CDINOT
bltext.get_line_containing
bltext.get_line_containing
HSU_CAPF.create_specification
HSU_CAPF.create_c_tabalias
HSU_CAPF.create_c_tabalias_all
HSU_CAPF.create_aggregate_value
HSU_CAPF.create_aggregate_value
HSU_CAPF.create_aggregate_value
Activity aborted with ORACLE internal errors.
-6502 ORA-06502: PL/SQL: numeric or value error: character string buffer too small
What can I do about it???
Thanks in advance.
Menno HoogsteenWorking on the same project as Menno, I had the time to look into the problem.
The problem is caused by the creation of the capi-function agregate_char_value in the packages hsu_capf. While creating this function the following code is executed:
add(' -- allowable values:');
add(' -- '||l_col_name_list);
This last statement causes the problem because this table is very big. L_col_name_list contains 2391 characters wich is 393 characters to long. So i changed this code into:
add(' -- allowable values:');
add(' -- '||substr(l_col_name_list,1,1990));
add(' -- '||substr(l_col_name_list,1990));
and everything works fine. Perhaps something for a patch?
Kind regards,
Ruben Spekle -
Numeric or value error when Attribute Usage Retrieve is set to Yes
When using the Business Rule Design Transformer in Headstart Utilities a Numeric or value error occurs when one of the attribute usages of an entity has the operation Retrieve set to Yes.
Sandra,
Thanks for your quick response!
The following debug detail info is logged:
-- START --
Transformation of Business Rule BR_3ARE1007_CEV.
Determine rule type for BR_3ARE1007_CEV.
BR_3ARE1007_CEV is change event with DML.
Stage 1: Populate in memory table with all triggering tables and columns.
Triggering event CREATE ARTICLE found.
Checking attribute usages for business rule 724784 and entity 720389
Attribute: PRIORITY
Column is:
Checking relationship usages for business rule 724784 and entity 720389
Stage 2: loop over all tables found and create BRDD.
...Create BRDD for table XPS_ARTICLES.
hsu_capi.find_plm
Business Rule Design Definition for BR_3ARE1007_CEV
Activity aborted with ORACLE internal errors.
-6502 ORA-06502: PL/SQL: numeric or value error
-- END --
If you want to reproduce the problem use the following data:
EVENT:
Name = CREATE test
Type = Change
On condition = CREATE
Entity = test
BUSINESS FUNCTION <BR_..>
Triggered by = Above event
Using entities = test
Using attributes = test_att
Retrieve? = Yes
This should create the error... -
Unexpected "numeric or value error" when using CAST COLLECT
I am having trouble with string aggregation using CAST / COLLECT and the to_string function described on various sites around the net including AskTom and http://www.oracle-developer.net/display.php?id=306.
I am getting "numeric or value error: character string buffer too small" but cannot see which limit I am exceeding.
I have put together a simple test case to highlight this problem which I have pasted below.
The error does not seem to be coming from the to_string function itself (else I expect we would see "TO_STRING raised an exception" in the returned error message).
Any thoughts much appreciated,
Thanks, Andy
SQL*Plus: Release 10.1.0.4.2 - Production on Tue Jun 15 09:56:53 2010
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL> CREATE TYPE table_of_varchar2 AS TABLE OF VARCHAR2(32000);
2 /
Type created.
SQL> CREATE OR REPLACE FUNCTION to_string (
2 nt_in IN table_of_varchar2
3 , delimiter_in IN VARCHAR2 DEFAULT ',')
4 RETURN VARCHAR2
5 IS
6 l_idx PLS_INTEGER;
7 l_str VARCHAR2(32767);
8 l_dlm VARCHAR2(10);
9
10 BEGIN
11
12 l_idx := nt_in.FIRST;
13 WHILE l_idx IS NOT NULL LOOP
14 l_str := l_str || l_dlm || nt_in(l_idx);
15 l_dlm := delimiter_in;
16 l_idx := nt_in.NEXT(l_idx);
17 END LOOP;
18
19 RETURN l_str;
20 EXCEPTION
21 WHEN OTHERS THEN
22 raise_application_error(-20000
23 , 'TO_STRING raised an exception. '||
24 'The reported error was: '||sqlerrm);
25 END to_string;
26 /
Function created.
SQL> DECLARE
2 l_longstring varchar2(32000);
3 BEGIN
4 SELECT to_string(CAST( COLLECT( substr(object_name,1,1) ) AS table_of_varchar2 ) )
5 INTO l_longstring
6 FROM all_objects
7 WHERE rownum < 2001;
8
9 EXCEPTION
10 WHEN OTHERS THEN
11 raise_application_error(-20001
12 , 'The anonymous block raised an exception: '||
13 sqlerrm||'. '||DBMS_UTILITY.format_error_backtrace);
14 END;
15 /
PL/SQL procedure successfully completed.
SQL> DECLARE
2 l_longstring varchar2(32000);
3 BEGIN
4 SELECT to_string(CAST( COLLECT( substr(object_name,1,1) ) AS table_of_varchar2 ) )
5 INTO l_longstring
6 FROM all_objects
7 WHERE rownum < 2002;
8
9 EXCEPTION
10 WHEN OTHERS THEN
11 raise_application_error(-20001
12 , 'The anonymous block raised an exception: '||
13 sqlerrm||'. '||DBMS_UTILITY.format_error_backtrace);
14 END;
15 /
DECLARE
ERROR at line 1:
ORA-20001: The anonymous block raised an exception: ORA-06502: PL/SQL: numeric
or value error: character string buffer too small
ORA-06512: at line 1. ORA-06512: at line 1
ORA-06512: at line 4
ORA-06512: at line 11Aha, of course.
I was aware of the 4000 character SQL VARCHAR2 limit but didn't think it would apply here since we are calling a PLSQL function and trying to assign the value it returns into a PLSQL varchar2(32000) variable. BUT... we are of course doing this via a SELECT statement and hence via SQL. Therefore the SQL 4000 limit applies.
With this in mind, I changed the RETURN type of the to_string function to be CLOB. This solved the problem.
Thank you,
Andy -
Numeric or value error when doing to_number
I have a source file where I have field1 character field with value say -5757.31. I need to map this feild to target table which is numeric field.
When I do the to_number of field1, do I need to specify the format?
When I am just doing to_number without any format, iam getting numeric or value error.
ThanksHi,
the implicit conversion depends on the nls parameters of your session. To be on the save side, define them explicitly: to_number('-5757.31', '9999999D99', 'NLS_NUMERIC_CHARACTERS = ''.,''')
Regards,
Carsten. -
PL/SQL: numeric or value error when extracting xml file from tables.
create or replace FUNCTION proc_generate_xml_from_tables(p_directory in varchar2,
p_areaname in varchar2)
return integer
AS
qryCtx DBMS_XMLGEN.ctxHandle;
result CLOB;
clob_len number := 0;
file_ptr utl_file.file_type;
oTableName restore_metadata.table_name%type;
o_filename restore_metadata.table_name%type;
cursor metadata_restore_list(p_area varchar2) is
select * from restore_metadata
where instr(area_name,upper(p_Area)) > 0
order by degree;
vtabcount number := 0;
sql_stmt varchar2(300);
BEGIN
dbms_lob.createtemporary(result, true,dbms_lob.session);
oTableName := upper('MAINT_ACTVS');
vtabcount := 0;
sql_stmt := 'select count(*) from ' || oTableName;
execute immediate sql_stmt into vtabcount;
o_filename := oTableName || '.xml';
file_ptr := utl_file.fopen(p_directory,o_filename,'W');
dbms_output.put_line(oTableName);
qryCtx := dbms_xmlgen.newcontext('select * from ' || oTableName);
result := dbms_xmlgen.getxml(qryCtx);
--dbms_output.put_line(result);
clob_len := dbms_lob.getlength(result);
dbms_output.put_line('Length of the clob file' || clob_len);
utl_file.put_line(file_ptr,result);
utl_file.fclose(file_ptr);
dbms_xmlgen.closeContext(qryCtx);
dbms_lob.freetemporary(result);
return 0;
EXCEPTION
when others THEN
utl_file.fclose(file_ptr);
dbms_output.put_line('Table Name into Consideration :- ' || oTableName);
dbms_output.put_line('Oracle Error Number:- ' || sqlcode || ' Ora Message :- ' || sqlerrm);
return -1;
END;
I am getting the following errors..
SQL> @temp1.sql
MAINT_ACTVS
Length of the clob file34245
Table Name into Consideration :- MAINT_ACTVS
Oracle Error Number:- -6502 Ora Message :- ORA-06502: PL/SQL: numeric or value error
What am I doing wrong here?
DB version is Oracle 10g
Edited by: userAtoZ on May 6, 2011 2:55 PM>
My problem lies that my xml file is having data more than 32 K.
When I write it 32K at a time then it work fine.
>
Then break it down.
l_pos number;
WHILE (l_pos <= clob_len)
LOOP
UTL_FILE.PUT_LINE (file_ptr,DBMS_LOB.SUBSTR ( RESULT , 32767,l_pos));
l_pos := l_pos + 32767;
END LOOP;
utl_file.fclose(file_ptr);
-
Error when submitting form to PHP server
Hi all,
I'm trying to submit a PDF file (as a whole, not just the data) to a PHP server. It works as far as the file being delivered and saved, but in Acrobat I keep getting an error message at the end of the process, saying: "No Input File Page Data".
I tried doing some research online and it seems to be related to the return value sent by the server to Acrobat, but I can't seem to get it to function properly.
We've tried using header('HTTP/1.1 204 No Content'); as the response, but it doesn't seem to help, either.
Any ideas would be much appreciated...The No Content approach should work. Can you show the exact code you're using to generate the response? Did you add "#FDF" to the end of the URL for the submit form action?
If you haven't looked into it already, consider returning an FDF that causes a popup dialog to display as a way of providing feedback. -
Getting "HTTP 400 Bad Request" error when submitting form
I am using APEX 3.1.2. I have a form based on a table. The form contains check boxes, a multiple select item, some text items and some text boxes with HTML editors. It had been working properly but now is giving me the dreaded "The web page can not be found..." error page as soon as I click create when in create mode or the update or the delete button when editing a row of data. The URL in the address area of the browser is: "http://ndhoast.tsh.mis.mckesson.com:7778/pls/apex/wwv_flow.accept" and the tab says "HTTP 400 Bad Request".
Any help would be greatly appreciated!Do you have any extra Javascript components added in? We've been doing work with ExtJS and Oracle Apex, and I've noticed that on one particular page there is a bad request thrown when a doSubmit() is called. When the Javascript is commented out, the page works fine.
-
Getting error when submitting form using IE but not when using FF
Error: Error #2101: The String passed to URLVariables.decode() must be a URL-encoded query string containing name/value pairs.
at Error$/throwError()
at flash.net::URLVariables/decode()
at flash.net::URLVariables()
at flash.net::URLLoader/onComplete()
Has anyone had this problem?I don't know how I would test that I don't know of any way to test it locally.
here's the code for the form:
import flash.net.*;
import flash.events.*;
import flash.text.TextField;
var status_txt:TextField = new TextField();
var myFormat:TextFormat = new TextFormat();
myFormat.font = "Georga";
myFormat.color = 0x00ff00;
myFormat.size = 21;
status_txt.autoSize = TextFieldAutoSize.LEFT;
status_txt.x = -240;
status_txt.y = -225;
addChild(status_txt);
submit_btn.addEventListener(MouseEvent.CLICK, ValidateAndSend);
stage.addEventListener(KeyboardEvent.KEY_DOWN, reportKeyDown);
//this.status_txt.mouseEnabled = false;
//this.parent.mouseEnabled = true;
function reportKeyDown(e:KeyboardEvent):void {
var KeyCode:uint = e.charCode;
if (KeyCode == 13){
submit_btn.dispatchEvent(new MouseEvent(MouseEvent.CLICK));
function ValidateAndSend(e:MouseEvent):void {
var variables:URLVariables = new URLVariables();
var request:URLRequest = new URLRequest();
// variables.recipient = "[email protected]";
if(!name_input.length){ createStatus("please enter a name"); }
else if(!email_input.length) {createStatus("please enter a email address");}
else if(!validateEmail(email_input.text)){createStatus("enter valid email address");}
else if(!message_input.length){createStatus("please enter a message");}
else {
variables.name = name_input.text;
variables.email = email_input.text;
variables.message = message_input.text;
request.url = "gdform.php";
request.method = URLRequestMethod.POST;
request.data = variables;
var loader:URLLoader = new URLLoader();
loader.dataFormat = URLLoaderDataFormat.VARIABLES;
loader.load(request);
createStatus("Thanks " + name_input.text + ", your message has been sent!");
function createStatus(msg:String):void {
status_txt.text = msg;
status_txt.setTextFormat(myFormat);
function validateEmail(str:String):Boolean {
var pattern:RegExp = /(\w|[_.\-])+@((\w|-)+\.)+\w{2,4}+/;
var result:Object = pattern.exec(str);
if(result == null) {
return false;
return true;
this is the php on the server that I submit to.
<?php
$request_method = $_SERVER["REQUEST_METHOD"];
if($request_method == "GET"){
$query_vars = $_GET;
} elseif ($request_method == "POST"){
$query_vars = $_POST;
reset($query_vars);
$t = date("U");
$file = $_SERVER['DOCUMENT_ROOT'] . "/../data/gdform_" . $t;
$fp = fopen($file,"w");
while (list ($key, $val) = each ($query_vars)) {
fputs($fp,"<GDFORM_VARIABLE NAME=$key START>\n");
fputs($fp,"$val\n");
fputs($fp,"<GDFORM_VARIABLE NAME=$key END>\n");
if ($key == "redirect") { $landing_page = $val;}
fclose($fp);
if ($landing_page != ""){
header("Location: http://".$_SERVER["HTTP_HOST"]."/$landing_page");
} else {
header("Location: http://".$_SERVER["HTTP_HOST"]."/");
?> -
SQL query concat - numeric or value error
I am getting numeric or value error when concatenating sql script..
Here is the sample, I have in the stored proc.. firstpart:_ works fine if I comment the secondpart:_. (I modified the query because I am posting in the public forums)
V_SAMPLEQUERY VARCHAR2(2000);
firstpart:_
V_SAMPLEQUERY := '
SELECT
AB.ABCDID AS ABCDID,
CD.MEMBERID AS MEMBERID,
CD.FNAME AS FNAME,
CD.LNAME AS LNAME,
CD.ACCOUNT AS ACCOUNT,
EF.ZIP AS ZIP,
AB.INSERTTIME AS INSERTTIME,
AB.INSERTBY AS INSERTBY,
ES.NAME AS STATUS,
MYFUNCTION(E.ABCDID) AS AMOUNT,
PA.NAME AS SOUSENAME,
R.CODE AS BUDGETCODE,
WX.ACCOUNTID as ACCOUNTID,
AB.SOMETYPE AS SOMETYPE,
AB.ACCTREP,
ED.TYPE AS TYPE,
AB.NOTES AS NOTES,
GH.AREACODE || '''' || GH.PHONE_NUMBER AS PHONENUMBER,
ED.REQUESTEDDATE,
ED.BOOKED,
ED.CALLERINFO
FROM PEOPLES AB,
LOCATIONS CD,
LOCATIONTYPES EF,
ACCOUNTS GH,
ACCOUNTdetails IJ,
ACCOUNTstatus KL,
ACCOUNTMEMBERDETAILS MN,
MEMBERS OP,
BUDGET QR,
BCODES ST,
ACCOUNTSYSTEM UV,
INFOCALL WX,
PHONE_NUMBERS YZ
WHERE AT.NAME = ''SAVINGS''
andCD.MEMBERID = PH.MEMBERID
andCD.MEMBERID =EF.MEMBERID
and AT.ADDRESSTYPEID =EF.ADDRESSTYPEID
andCD.MEMBERID =AB.MEMBERID
andAB.STATUS = ES.STATUS(+)
andAB.ABCDID = ED.ABCDID
andAB.ABCDID = EP.ABCDID(+)
and EP.MEBER_ID = PA.MEBER_ID(+)
andAB.BID = R.BID(+)
andAB.SAMPLEID = PR.SAMPLEID(+)
andAB.ABCDID = BSG.ABCDID(+)
andAB.INFOCALLID = C.INFOCALLID(+)
and YZ.SOMETYPEID = ''10000''
ANDAB.INSERTTIME > SYSDATE - 35
ANDAB.INSERTTIME < ''
AND WX.NAME IN (''ABCD'',
''EFGH'',
''IJKL'',
''MNOP'',
''QRST'',
''UVWX'')
AND MN.NAME = ''FINISHED'' '
secondpart:_ ***ERROR PART***
V_SAMPLEQUERY := V_SAMPLEQUERY || ' ORDER BY AB.USER'; -- Here I am getting error saving ORA-06502 - numeric or value errorHi,
Wheneve you have a problem, prlease post a complete test script that people can run to re-create the problem and test their ideas. Include CREATE TABLE and INSERT statements for any tables used, abnd the results you want it to produce.
SeshuGiri wrote:
I am getting numeric or value error when concatenating sql script.. Are you really getting the error when you concatenate, or when you try to execute the resulting string?
Here is the sample, I have in the stored proc.. firstpart:_ works fine if I comment the secondpart:_. (I modified the query because I am posting in the public forums)
V_SAMPLEQUERY VARCHAR2(2000);Is that big enough? It looks like the string is right around 1000 characters; depending on your character set, that could be more than 2000 bytes. VARCHAR2s in PL/SQL can hold up to 32767 bytes.
firstpart:_
V_SAMPLEQUERY := '
SELECT
AB.ABCDID AS ABCDID,
CD.MEMBERID AS MEMBERID,
CD.FNAME AS FNAME,
CD.LNAME AS LNAME,
CD.ACCOUNT AS ACCOUNT,
EF.ZIP AS ZIP,
AB.INSERTTIME AS INSERTTIME,
AB.INSERTBY AS INSERTBY,
ES.NAME AS STATUS,
MYFUNCTION(E.ABCDID) AS AMOUNT,
PA.NAME AS SOUSENAME,
R.CODE AS BUDGETCODE,
WX.ACCOUNTID as ACCOUNTID,
AB.SOMETYPE AS SOMETYPE,
AB.ACCTREP,
ED.TYPE AS TYPE,
AB.NOTES AS NOTES,
GH.AREACODE || '''' || GH.PHONE_NUMBER AS PHONENUMBER,
ED.REQUESTEDDATE,
ED.BOOKED,
ED.CALLERINFO
FROM PEOPLES AB,
LOCATIONS CD,
LOCATIONTYPES EF,
ACCOUNTS GH,
ACCOUNTdetails IJ,
ACCOUNTstatus KL,
ACCOUNTMEMBERDETAILS MN,
MEMBERS OP,
BUDGET QR,
BCODES ST,
ACCOUNTSYSTEM UV,
INFOCALL WX,
PHONE_NUMBERS YZ
WHERE AT.NAME = ''SAVINGS''
andCD.MEMBERID = PH.MEMBERID
andCD.MEMBERID =EF.MEMBERID
and AT.ADDRESSTYPEID =EF.ADDRESSTYPEID
andCD.MEMBERID =AB.MEMBERIDYou need some whitespace after the keyword "and", in the line above and also several places below.
andAB.STATUS = ES.STATUS(+)
andAB.ABCDID = ED.ABCDID
andAB.ABCDID = EP.ABCDID(+)
and EP.MEBER_ID = PA.MEBER_ID(+)
andAB.BID = R.BID(+)
andAB.SAMPLEID = PR.SAMPLEID(+)
andAB.ABCDID = BSG.ABCDID(+)
andAB.INFOCALLID = C.INFOCALLID(+)
and YZ.SOMETYPEID = ''10000''
ANDAB.INSERTTIME > SYSDATE - 35
ANDAB.INSERTTIME < '' Did something get cut off here?
AND WX.NAME IN (''ABCD'',
''EFGH'',
''IJKL'',
''MNOP'',
''QRST'',
''UVWX'')
AND MN.NAME = ''FINISHED'' 'It looks like you're constructing a string for EXECUTE IMMEDIATE, but why not just use a static query?
secondpart:_ ***ERROR PART***
V_SAMPLEQUERY := V_SAMPLEQUERY || ' ORDER BY AB.USER'; -- Here I am getting error saving ORA-06502 - numeric or value error
USER is the name of a built-in function, which means it's not a good name for your own column. Try user_name instead. -
I need help with error ORA-06502: numeric or value error
Hi, all, i need help finding the error here, im getting a numeric or value error when i add information to the variable vlcadena when vlcadena is a clob type, and i check the length of the vlcadena variable and sometimes makes the error at 8000 characters some other times 32k i have no idea whats happening, does anyone have a clue?
PROCEDURE REGISTRO_551 (
VPNUMPARTE IN PARTESC.NUMPARTE%TYPE,
VPFRACCION IN IMPOMAT.FRACCIONMEXIMPO%TYPE,
VPDESCRIPCION IN PARTESC.DESCESPANOL%TYPE,
VPVALORDLS IN IMPOMAT.VALORDOLARES%TYPE,
VPCANTIDAD IN IMPOMAT.CANTIDAD%TYPE,
VPUNIMED IN PARTESC.UNIMEDPARTE%TYPE,
VPCANTIDADTARIFA IN IMPOMAT.CANTIDAD%TYPE,
VPVALORAGREGADO IN EXPOPT.VALORAGREGADO%TYPE,
VPPAISORIGEN IN PARTESC.PAISORIGEN%TYPE,
VPCOMPVEND IN PARTESC.PAISORIGEN%TYPE,
VPTIPOFRACCION IN IMPOMAT.TIPOFRACCION%TYPE,
VPPESONETO IN IMPOMAT.PESONETO%TYPE,
VPTIPOMONEDA IN MIMPOMAT.TIPOMONEDAEXTRANJERA%TYPE
) AS
BEGIN
vgproceso := 207310;
vllong2:=length(vlCadena);
vlCadena:=vlCadena||'551'||'|'; --1. TIPO DE REGISTRO
vgproceso := 207311;
vllong2:=length(vlCadena);
vlCadena:=vlCadena||VPFRACCION||'|'; --2. FRACCION
vgproceso := 207312;
vllong2:=length(vlCadena);
QUITA_ENTERS(NVL(VPDESCRIPCION,' '),VLTEMP);
IF LENGTH(VLTEMP)>80 THEN
VLTEMP:=SUBSTR(VLTEMP,1,80);
END IF;
vgproceso := 207313;
vllong2:=length(vlCadena);
IF VLTEMP IS NULL THEN
vlCadena:=vlCadena||'|'; --3. DESCRIPCION
ELSE
vlCadena:=vlCadena||VLTEMP||'|'; --3. DESCRIPCION
END IF;
vgproceso := 207314;
vllong2:=length(vlCadena);
IF VPNUMPARTE IS NULL THEN
vlCadena:=vlCadena||'|';--4. NO. DE PARTE
ELSE
vlCadena:=vlCadena||VPNUMPARTE||'|';--4. NO. DE PARTE
END IF;
vgproceso := 207315;
vllong2:=length(vlCadena);
vlCadena:=vlCadena||VPVALORDLS||'|'; --5. VALOR MERCANCIA
vgproceso := 207316;
vllong2:=length(vlCadena);
vlCadena:=vlCadena||VPCANTIDAD||'|'; --6. CANTIDAD COMERCIAL
vgproceso := 207317;
vllong2:=length(vlCadena);
IF VPUNIMED IS NULL THEN
VPDESCERROR:='ALGUNA PARTIDA CON FRACCION '||VPFRACCION||' NO TIENE UNIDAD DE MEDIDA';
END IF;
vgproceso := 207320;
GET_CATGRAL('ADUANAS','UNIMED',NVL(VPUNIMED,' '),CL_D1,CL_D2,CL_D3,CL_D4,CL_V1,CL_V2,CL_V3,CL_CATG);
IF CL_V2=0 THEN
vlCadena:=vlCadena||VPUNIMED||'|'; --7. UNIDAD MEDIDA COMERCIAL
ELSE
SELECT TO_CHAR(TRUNC(CL_V2)) INTO VLUMCOMERCIAL FROM DUAL;
IF LENGTH(VLUMCOMERCIAL)=1 THEN
VLUMCOMERCIAL:='0'||VLUMCOMERCIAL;
END IF;
vlCadena:=vlCadena||VLUMCOMERCIAL||'|'; --7. UNIDAD MEDIDA COMERCIAL
END IF;
vlCadena:=vlCadena||VPCANTIDADTARIFA||'|';--8. CANTIDAD TARIFA
vlCadena:=vlCadena||VPVALORAGREGADO||'|';--9. VALOR AGREGADO
GET_CATGRAL('ADUANAS','CONFADU','IVIN-REG',CL_D1,CL_D2,CL_D3,CL_D4,CL_V1,CL_V2,CL_V3,CL_CATG);
vlCadena:=vlCadena||CL_D1||'|'; --10. VINCULACION
vlCadena:=vlCadena||CL_D2||'|'; --11. METODO DE VALORACION
vlCadena:=vlCadena||'|'; --12. MARCA
vlCadena:=vlCadena||'|'; --13. MODELOIf the expected maximum length of the concatenated string is less than 32K, then use VARCHAR2 and at the end convert to CLOB if necesary.
:p
PS: At what line in the code does it give the error?
Edited by: LKBrwn_DBA on Aug 20, 2009 2:49 PM -
Hi All,
Can somebody help me out here urgently. I just added a New Column to a Table & when I try to use that Column in a Form & Insert using Automatic Row Processing(DML). I am getting this error, If I remove the newly created column, then it is fine.
Please help. I saw some posting on forum, but there was no solution.
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
Error Unable to process row of table <tablename>
OK
Thanks
SandeepSandeep - Looks like you're hitting a 4096-character limit for the values portion of the insert statement because you have so many columns. This is a bug. A workaround would be to reduce the number of columns or create your own DML process for the insert operation.
Also just now I installed htmldb 2.0 in my laptop & trying to create the same table, but it is not creating ...no errors ..just a clue...I don't understand what you said.
Scott -
Error"There was an internal error when submitting the form" URM Disposition
Hello
I get the following error - "*There was an internal error when submitting the form*" - when i allocate a Retention Disposition to a Retention Category.
Any Ideas how this can be solved?
Thank youNot based on the minimal information provided.
Error messages in 11g, from a UI standpoint, are severely deficient. How about looking in the content server logs and posting some more information? -
We face the above error in HTMLDB (APEX) application Ver 3.1.0. This occurs when we try to display more number of rows/records in drop-down list (LOV in tabular forms). We are able to display 200 records in LOV. When the list of records exceeds 230, we face the below error
report error:ORA-06502: PL/SQL: numeric or value error: character string buffer too small
the values listed in LOV are from tables (one of the columns in table)
Could anyone give us a solution?Hi
As you are using a tabular form, you could actually do the following:
1 - In the tabular form column's attributes, set the following:
Display as: Select List (query based on LOV)
Display extra values: Yes
List of values definition: SELECT null d, null r FROM DUAL
2 - Add a new page item and set it to generate your select list
3 - Create an HTML region with no template and use the following for its source:
<script type="text/javascript">
function loadList(c, l)
var s = document.getElementsByName(c);
var lItem = document.getElementById(l);
var lLength = lItem.options.length;
var k;
var j;
var x = lItem.innerHTML;
var v;
var o;
var z;
for (k = 0; k < s.length; k++)
z = s[k];
v = z.value;
z.options.length = 0;
for (j = 0; j < lLength; j++)
o = new Option()
o.value = lItem[j].value;
o.text = lItem[j].text;
z.options[j] = o;
z.value = v;
if (z.selectedIndex == -1)
z.selectedIndex = 0;
loadList("f05", "P1_MGR");
</script>
(Change "f05" and "P1_MGR" as appropriate to your column and your new page item respectively)
Now, when you load the page, the select list contains a null entry plus the entry already on the database. The javascript kicks in automatically, loops through every entry in the "f05" column, copies the existing value, replaces the select list with the new page item version and sets its value to the copied value.
Your new page item could be in a DIV tag that has a style of "display:none" to hide it from view.
Andy
Maybe you are looking for
-
Difference between implicit and explicit enhancement points
Hi Folks, I had learned many documents to findout the difference between explicit and implicit enhancement point.I got the theoritical knowledge on that but losing on the practical side.. Can anybody help me out with one real time scenario where the
-
User Login(s) / Account gone - BUG - thread overview - summary - solutions?
Hello everyone... Time to open a new thread... Seems there is a serious bug going on since a while with 10.6 randomly, hit me saturday. After working late switched off my iMac and next morning all my user accounts were gone, not able to login with my
-
Please help...my browser can't display applets
I know it might sound inept to be asking something about my mozilla browser in this forum but right now I am studying Java and using my browser to view the applet exercises I make. I am particularly in the methods section where you have to make recur
-
I recently got a DSL connection which requires PPPoE. The connection works just fine. However, every half hour or so while I am connected I get a box popping up in the middle of my screen which says... Internet Connect This is your reminder that your
-
The History Eraser in Inaction
I have had the need to do a specific erasure and can't seem to do it. I have a file with a b&w conversion layer applied. I come back a few days later and decide that a portion of the image needs attention, so I open the b&w layer and make a few chang