Non numeric value in numeric field giving error

Hi All
I am using BAPI for creating sales order. If user is giving non numeric value in Quantity field it is giving error. Because quantity field data type is Double.
Please Help.
Thanks
Raktim

Hi Banerjee,
             Create a String/int/long Context variable and point it to UI Input element.Do the validation  for correct input value. once the validation is succesful assign that value to RFC BigDecimal variable by Explicit casting.
Hope this might solve your problem .
Thanks
Madhan

Similar Messages

  • How to check non-numeric value in a field

    Hi all,
    I have a field 'MVALUE'. HOw can I check if I have a non-numeric value in my field. Let us say if I have a value '<25' in this field. How can I check if the value in this field is non-numeric. The field MVALUE is of CHAR datatype.
    Please help. Waiting.........

    Might have to add a space in the string...
    if not mvalue co ' 0123456789'.
    * error
    endif.
    if you allow decimals and commas...
    if not mvalue co ' .,0123456789'.
    * error
    endif.

  • Entering numeric values in CHAR field without quotes

    We are upgrading from Oracle 9i to 10g. In 9i we were able to add numeric data into a CHAR field without single quotes like
    insert into table (id, name, ...) values (1, 'some name', ....)
    When we migrated to 10g, we are getting database errors.
    Any ideas on what can be causing this and why it worked on 9i and not on 10g?
    Thanks

    Got an example, it seems to be working fine for me.
    ME_XE?create table tttttest( char_col char (5));
    Table created.
    Elapsed: 00:00:00.46
    ME_XE?insert into tttttest values (111);
    1 row created.
    Elapsed: 00:00:00.65
    ME_XE?select * from tttttest;
    CHAR_COL
    111
    1 row selected.
    Elapsed: 00:00:00.39
    ME_XE?
    ME_XE?@version
    BANNER
    Oracle Database 10g Express Edition Release 10.2.0.1.0 - Product
    PL/SQL Release 10.2.0.1.0 - Production
    CORE    10.2.0.1.0      Production
    TNS for Linux: Version 10.2.0.1.0 - Production
    NLSRTL Version 10.2.0.1.0 - Production
    5 rows selected.
    Elapsed: 00:00:00.57
    [pre[                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Maintaining Numeric Values in Alphanumeric field of Material Master

    Hello Everyone!
    Currently we are in midst of an SAP Project implementation. The problem arising is that we are using External Number for material codes which has already been used by the business in the legacy system. So the material code field has been set to Alphanumeric data type.
    During the data upload of material master a problem has been identified that some of the material codes that needs to be uploaded are number in nature or start with a numeral e.g 1234-5674-9, 1234-9876-D. While creating them the system generates the following error.
    Number 1234-5674-9 not defined for material type ICI PNT - Trading Goods
    Message no. M3318
    Diagnosis
    Every material type has a speific number range for external number assignment. The material number you have entered does not lie within the number range for this material type.
    Procedure
    Choose a material number that lies within the number range of your material type.
    Is there a way through which we can maintain such external numbers with Alphanumeric field.
    - Best Regards

    Hi Khalid,
    You assign as follows for external number range to your group
    From Number                                      to Number                                                                                EXT
    A                                                         ZZZZZZZZ( enter the number
                                                                    characters( Z) as required for your client)                                    Tick the Ext box
    By this setting you can assign ALPHA NUMERICAL external numbers
    Cheers
    Chris
    Edited by: CHRIS MM on Dec 27, 2010 9:27 AM

  • How to remove numeric value in the fields of a table

    Environment: SQL Server 2008R2
    Tools: MSMS
    Code:
    a. Table Definition 
    USE [DLPT_CMS1_RESTORE]
    CREATE TABLE [dbo].[Mocha]
    [id] [int] IDENTITY(80,1) NOT NULL,
    [Login_ID] [char](10) NULL,
    [PE4] [varchar](8000) NULL,
    [PE9] [varchar](8000) NULL,
    [PE11] [varchar](8000) NULL,
    [PE15] [varchar](8000) NULL,
    [PE17] [varchar](8000) NULL,
    [PE20] [varchar](8000) NULL,
    [PE22] [varchar](8000) NULL,
    [PE25] [varchar](8000) NULL,
    [PE28] [varchar](8000) NULL,
    [PE29] [varchar](8000) NULL,
    [PE27] [varchar](8000) NULL
    b. data
    Insert into Mocha (Login_ID,[PE4],[PE9] ,[PE11],[PE15],[PE17],[PE20],[PE22],[PE25],[PE28], [PE29],[PE27])
    Values (293595,293595,293737,293737,293737,293737,293737,293737,'I dont think 12 week program is hard',293737,293737,'antiinflamatory- this helps to fight free radicals and ward off disease.')
    Insert into Mocha (Login_ID,[PE4],[PE9] ,[PE11],[PE15],[PE17],[PE20],[PE22],[PE25],[PE28], [PE29],[PE27])
    Values (293841,293841,293841,293841,'293841 I feel that the product should be more holistic'
    ,'293841 I would like for the customer support to give more immediate feedback'
    ,'293841 Fends off alzeimer disease and dementia. It has been proven to destroy the amaloid plaques that are believed to be a cause of dementia and memory loss',
    293841,293841,293841,293841,293841,293841)
    Challenge: 
    1. Delete / Remove login_ids from a string found in one or more of the fields in Mocha table 
    Example: the following string contains login_id '293841 I would like for the customer support to give more immediate feedback' , remove the login_id in the narrative field which could be PE4, PE22. or PE28
    2. Count the response or narrative field for each column after the deletion is completed 
    My script and still working progress
    SELECT * FROM MOCHA
    WHERE ISNUMERIC(PE4) = 1 and [PE4] like '%[0-9]%'
    Thanks for the support

    I added a new data which shows inaccurate results using your last updated code. The mistake appears in the 3rd row culomn name PE25 is null but counts it as 1 
    CREATE TABLE [dbo].[Mocha]
    [id] [int] IDENTITY(80,1) NOT NULL,
    [Login_ID] [char](10) NULL,
    [PE4] [varchar](8000) NULL,
    [PE9] [varchar](8000) NULL,
    [PE11] [varchar](8000) NULL,
    [PE15] [varchar](8000) NULL,
    [PE17] [varchar](8000) NULL,
    [PE20] [varchar](8000) NULL,
    [PE22] [varchar](8000) NULL,
    [PE25] [varchar](8000) NULL,
    [PE28] [varchar](8000) NULL,
    [PE29] [varchar](8000) NULL,
    [PE27] [varchar](8000) NULL
    Insert into Mocha (Login_ID,[PE4],[PE9] ,[PE11],[PE15],[PE17],[PE20],[PE22],[PE25],[PE28], [PE29],[PE27])
    Values (293737,293737,293737,293737,NULL,293737,NULL,293737,'I dont think 12 week program is hard',293737,293737,'antiinflamatory- this helps to fight free radicals and ward off disease.')
    Insert into Mocha (Login_ID,[PE4],[PE9] ,[PE11],
    [PE15],[PE17]
    ,[PE20],[PE22],[PE25],[PE28], [PE29],[PE27])
    Values (293841,293841,293841,293841
    ,'293841 I feel that the product should be more holistic'
    ,'%%293841%% I would like for the customer support to give more immediate feedback'
    ,'%%293841%% Fends off alzeimer disease and dementia. It has been proven to destroy the amaloid plaques that are believed to be a cause of dementia and memory loss'
    ,293841,NULL,NULL,293841,293841)
    Insert into Mocha (Login_ID,[PE4],[PE9] ,[PE11],[PE15],[PE17],[PE20],[PE22],[PE25],[PE28], [PE29],[PE27])
    Values (293735,'293735 my name',NULL,NULL,NULL,NULL,NULL,NULL,'%%293735%%I dont think',293735,293735,'this helps to fight free radicals and ward off disease')
    select
    Replace(Replace(PE4,RTRIM(Cast(Login_ID as varchar(10))), ''),'%','') PE4
    ,Replace(Replace(PE9,RTRIM(Cast(Login_ID as varchar(10))), ''),'%','') PE9
    ,Replace(Replace(PE11,RTRIM(Cast(Login_ID as varchar(10))), ''),'%','') PE11
    ,Replace(Replace([PE15],RTRIM(Cast(Login_ID as varchar(10))), ''),'%','') PE15
    ,Replace(Replace(PE17,RTRIM(Cast(Login_ID as varchar(10))), ''),'%','')PE17
    ,Replace(Replace(PE20,RTRIM(Cast(Login_ID as varchar(10))), ''),'%','') PE20
    ,Replace(Replace(PE22,RTRIM(Cast(Login_ID as varchar(10))), ''),'%','') PE22
    ,Replace(Replace(PE22,RTRIM(Cast(Login_ID as varchar(10))), ''),'%','') PE25
    ,Replace(Replace(PE28,RTRIM(Cast(Login_ID as varchar(10))), ''),'%','') PE28
    ,Replace(Replace(PE22,RTRIM(Cast(Login_ID as varchar(10))), ''),'%','') PE29
    ,(case when len(PE4)-Len(Replace(PE4,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe4] is null or Replace(PE4,RTRIM(Cast(Login_ID as varchar(10))), '') ='' Then 0 Else 1 End) cntP4
    ,(case when len(PE9)-Len(Replace(PE9,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe9] is null or Replace(PE9,RTRIM(Cast(Login_ID as varchar(10))), '') ='' Then 0 Else 1 End) cntP9
    ,(case when len(PE9)-Len(Replace(PE11,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe11] is null or Replace(PE11,RTRIM(Cast(Login_ID as varchar(10))), '') ='' Then 0 Else 1 End) cntP11
    ,(case when len(PE15)-Len(Replace(PE15,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe15] is null or Replace(PE15,RTRIM(Cast(Login_ID as varchar(10))), '') ='' Then 0 Else 1 End) cntP15
    ,(case when len(PE17)-Len(Replace(PE17,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe17] is null or Replace(PE17,RTRIM(Cast(Login_ID as varchar(10))), '') ='' Then 0 Else 1 End) cntP17
    ,(case when len(PE20)-Len(Replace(PE20,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe20] is null or Replace(PE20,RTRIM(Cast(Login_ID as varchar(10))), '') ='' Then 0 Else 1 End) cntP20
    ,(case when len(PE22)-Len(Replace(PE22,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe22] is null or Replace(PE22,RTRIM(Cast(Login_ID as varchar(10))), '') ='' Then 0 Else 1 End) cntP22
    ,(case when len(PE25)-Len(Replace(PE25,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe25] is null or Replace(PE25,RTRIM(Cast(Login_ID as varchar(10))), '') ='' Then 0 Else 1 End) cntP25
    ,(case when len(PE28)-Len(Replace(PE28,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe28] is null or Replace(PE28,RTRIM(Cast(Login_ID as varchar(10))), '') =''Then 0 Else 1 End) cntP28
    ,(case when len(PE29)-Len(Replace(PE29,RTRIM(Cast(Login_ID as varchar(10))), ''))=0 or [pe29] is null or Replace(PE29,RTRIM(Cast(Login_ID as varchar(10))), '') =''Then 0 Else 1 End) cntP29
    from mocha

  • MOdify with Date field giving error

    Hi,
    I have to modifuy an internal table using modify statement.
    After using the modify statement my date field in the internal table is replace by *.
    heres a sample code i have used to depict the scenario(with the test values:)
    DATA: BEGIN OF t_arcs_source OCCURS 0,
          premise(10) type c,
        key_date TYPE sy-datum,
      END OF t_arcs_source.
      DATA: wa_arcs_source LIKE LINE OF t_arcs_source.
    t_arcs_source-premise = '1001'.
    t_arcs_source-key_date = '20080101'.
    APPEND t_arcs_source.
    t_arcs_source-premise = '1001'.
    t_arcs_source-key_date = '20090101'.
    APPEND t_arcs_source.
      sort t_arcs_source by premise ascending key_date descending.
      clear t_arcs_source.
      loop at t_arcs_source into wa_arcs_source.
        at new premise.
           modify t_arcs_source from wa_arcs_source transporting key_date where premise = wa_arcs_source-premise.
        endat.
      endloop.
    please test the code and see the  error and help me out.
    Regards,
    Anand

    Hi.
    I have modify ur above given code and make it changed for ur need meanz according ur nedd and it is working accurately.
    check it and then tell me.
    DATA: BEGIN OF t_arcs_source OCCURS 0,
          premise(10) type c,
        key_date TYPE sy-datum,
      END OF t_arcs_source.
    " New code of loines i appended
      data: wa_t_arcs_source like t_arcs_source.
      data: t_arcs_source_1 LIKE STANDARD TABLE OF t_arcs_source WITH HEADER LINE.
      data: wa_t_arcs_source_1 like t_arcs_source.
    " End of new code of line
      DATA: wa_arcs_source LIKE LINE OF t_arcs_source. " I change this work area by wa_t_arcs_source
    t_arcs_source-premise = '1001'.
    t_arcs_source-key_date = '20080101'.
    APPEND t_arcs_source.
    t_arcs_source-premise = '1001'.
    t_arcs_source-key_date = '20090101'.
    APPEND t_arcs_source.
      sort t_arcs_source by premise ascending key_date descending.
      clear t_arcs_source.
      loop at t_arcs_source into wa_t_arcs_source. " Used the new work area
        wa_t_arcs_source_1 = wa_t_arcs_source.
        append wa_t_arcs_source_1 to t_arcs_source_1.
        at new premise.
           modify t_arcs_source_1 from wa_t_arcs_source_1 transporting key_date where premise = wa_t_arcs_source-premise.
        endat.
      endloop.
    Just copy paste in editor and check it.
    Edited by: tahir naqqash on Feb 2, 2009 11:24 AM

  • Weekday & Weekday Name Calculated Field giving error

    Hi all,
    I'm trying to learn how SSRS works, but I've reached an issue or error I just cannot find the solution for.
    What I'm trying to do is create a calculated field that shows me the number of the day of the week and the name of the weekday. The problem: instead of calculating for example 14/06/2002 as the 5th day of the week Friday, it calculated it as the 6th day, Saturday.
    Below is the example of my problem:
    Can somebody please explain to me, how can I overcome this issue?

    Hi Ellie55,
    According to your description that the you want to get the number of the weekday and also the name of it, but when you are using the expression in the calculated fields, the result always show the value one more days ahead of the exact day, right?
    I have tested in my local environment and can reproduce your problem, the problem related to the method WEEKDAY(date) you use in the expression which Week begins on Sunday (1) and ends on Saturday (7),This article will give details information:
    WEEKDAY Function
    WeekdayName Function
    So you will get the day one more ahead. You can take below expression for reference to do a little modification to your expression:
    Get the weekday number, we can make the “WEEKDAY(Date)-1 “ and make the Sunday to be the number of 7,then the number will be Monday(1)and ends on Sunday(7) :
    =IIF(WEEKDAY(Fields!YourDate.Value)="1",7,WEEKDAY(Fields!YourDate.Value)-1)
    Get the weekday name(This method base on the exact date, it is not based on the number of the week, so will not have the problem you have faced ):
    =WeekdayName(weekday(Fields!YourDate.Value),true)
    If you still have any question, please feel free to ask.
    Regards
    Vicky Liu

  • Email Attachment SQL field giving error without attachment...

    Hi All,
    I'm running Apex 4.1.0.X on 10g and trying to solve the following problem with little success.
    After reviewing the OBE on Viewing and Downloading BLOBS within Apex 3.1 from here -http://www.oracle.com/webfolder/technetwork/tutorials/obe/db/apex/r31/apex31nf/apex31blob.htm...
    I was able to create a simple form to send an email with an attachment as well as a simple report from which to view the stored email messages send and the attachments associated with them. All good, all working just fine. Problem comes about when I try to send a message without an attachment. When I do this, I get the following error:
    ~~~
    ORA-20022: Null value supplied for parameter p_attachment.
    ~~~
    I have two process...one to store the message content in the table (Process Row of EMAIL_NOTIFICATIONS with source type as Automatic Row Processing DML) and a second to send the email which is just the canned mailer in Apex. I have defined the Attachment SQL field as follows:
    select attachment, att_file_name, att_mime_type from email_notifications where subject = '&P88_SUBJECT.' and body = '&P88_BODY.' and sender = '&P88_SENDER.'...There is no primary key on the table as there is a high likelihood that duplicate messages will be sent....so I am attempting to use the combination of three fields together to make sure that the correct BLOB is attached to the outgoing email....with no where condition...the wrong BLOBS were being attached....tried using ROWID as a unique record but it kept coming back null and no BLOBS could be attached.
    Anyway....hope I haven't made the issue too unclear.
    Thanks for any help. Mike
    Quick Edit...Just want to reiterate...as strange as the above "Attachment SQL" used in the canned Email Process seems...in testing it does seem to do the job....only snag is when no attachment is added....in case the error is presented and no record was saved to the table or sent in email.....My hope would be some crafty way in which to NOT use attachment SQL when there is no attachment.
    Thanks!
    Edited by: Twinkle Berry Sunshine on Jun 26, 2012 9:56 AM

    Yes...you can attach BLOBS to emails...there is a MIME_TYPE attribute which is automatically inserted with the BLOB...I have this successfully working emails with attachments stored as BLOBS....so long as: 1.) There "MUST" be an attachment 2.) I use the syntax you said should work... where subject = '&P88_SUBJECT.' The documentation talks of using pl/sql method which I'll now try instead of what I was using:
    http://docs.oracle.com/cd/E23903_01/doc/doc.41/e21676/apex_mail.htm#CHDHCEGF

  • Numeric Value Out Of Range Error in Callable Statement

    I keep getting an error whenever I try and pass in a value greater than 9000 into my stored procedure. The procedure call looks like this:
    sSelect = "execute sp_storedproc ?, ?, ?, ?, ?, ?, ?";
    CallableStatement call = objConn.prepareCall(sSelect);
    call.setString(1, "TEST"); //DB TYPE = VARCHAR
    call.setInt(2, 4); // DB TYPE = INTEGER
    //*******************PROBLEM LINE***************************
    call.setFloat(3,(float) 9001); //DB TYPE = MONEY
    call.setInt(4, 25 ); // DB TYPE = INTEGER
    call.setFloat(5,(float) 0); // DB TYPE = MONEY
    // output parameters
    call.setDouble(6, 0);
    call.setDouble(7, 0);
    call.registerOutParameter(6, Types.DOUBLE);
    call.registerOutParameter(7, Types.DOUBLE);
    // execute stored procedure
    call.execute();
    // retrieve value
    val1= call.getDouble(6);
    val2= call.getDouble(7);
    I keep getting a "[Microsoft][ODBC SQL Server Driver]Numeric value out of range." error.
    I'm using MS SQL server 2000. The error only occurs when I pass in values > 9000. Since there's no direct mapping between java data types and SQL MONEY data type, I've tried passing every possible type into the procedure with the same result (e.g. float, long, double, int, BigDecimal). If anyone has come across this problem and knows a solution please help!!
    Thanks.

    knows a solution please help!!Modify the stored proc so it takes a varchar. In the stored proc convert the string to the correct type. In java use setString() to pass in the value.

  • Popup Key LOV, NULL and "Invalid numeric value undefined for column"

    Hello.
    I've created an item based on database column of NUMBER type and set the following properties:
    Display As = Popup Key LOV (Displays description, returns key value)
    List of values definition=select 'display_value' d, 1 r from dual
    Null display value=%
    Null return value=
    Display Null=Yes
    When I select "%" in the LOV and try to apply changes to database I get error:
    ORA-20001: Error in DML: p_rowid=1781, p_alt_rowid=N1, p_rowid2=, p_alt_rowid2=. ORA-20001: Invalid numeric value undefined for column N2
    Error Unable to process row of table TTT.
    If I set Display As = Select List, all works fine. But I need Popup Key LOV.
    Could anybody help me?
    I use Application Express 2.2.1.00.04

    Hi all,
    I did my homework and solved this issue. First I would like to thank Patrick Wolf for the invaluable help he gives out on thread Re: Null value handling in LOVs The code presented here is just a minor edit to his code, but an essential one when dealing with Popup Key LOV items.
    Here's what I did:
    1. Create an Application Process.
    Name: RemoveNulls
    Sequence: 0
    Point: On Submit: After Page Submission - Before Computations and Validations
    Process Text:
    BEGIN
        FOR rItem IN
          ( SELECT ITEM_NAME
              FROM APEX_APPLICATION_PAGE_ITEMS
             WHERE APPLICATION_ID   = TO_NUMBER(:APP_ID)
               AND PAGE_ID          IN (TO_NUMBER(:APP_PAGE_ID), 0)
               AND LOV_DISPLAY_NULL = 'Yes'
               AND LOV_DEFINITION   IS NOT NULL
               AND LOV_NULL_VALUE   IS NULL
        LOOP
            IF (V(rItem.ITEM_NAME) = '%null' || '%' OR V(rItem.ITEM_NAME) = 'undefined')
            THEN
                Apex_Util.set_session_state(rItem.ITEM_NAME, NULL);
            END IF;
        END LOOP;
    END;Error Message: #SQLERRM#Condition: None
    2. You should be able to submit a Popup Key LOV with a NULL value now.
    Once again, THANKS, Patrick! You rock! I'm seriously thinking of trying ApexLib now :)
    Georger

  • Store an encrypted numeric value and make the unencrypted value visible to just some users in Apex

    I'm looking for a way to store an encypted numeric value in one field in a table (so that it appears encrypted even to a DBA) and to display the unencypted value in Apex forms and interactive reports for some users but not others.
    Any suggestions as to how I could achieve this?
    Thanks in advance.
    Martin

    Try these documents:
    Using Column Masking to Display Sensitive Columns as NULL Values
    Using VPD in an APEX Application
    Securing Stored Data Using Transparent Data Encryption
    The features you request are Database Features.
    You could use DBMS_CRYPTO for data encryption instead of TDE, but you will have to create a package for your insert,update, deletes along with a view that allows decryption based on v('APP_USER').
    Also, you won't be able to search on that column if you use DBMS_CRYPTO.

  • How to restrict the user to enter only numeric values in a input field

    How to restrict the user to enter only numeric values in a input field.
    For example,
    i have an input field in that i would like to enter
    only numeric values. no special characters,alphabets .
    reply ASAP

    Hi Venuthurupalli,
    As valery has said once you select the value to be of type integer,once you perform an action it will be validated and error message that non numeric characters are there will be shown. If you want to set additional constraints like max value, min value etc you can use simple types for it.
    On the project structure on left hand side under local dictionary ->datatypes->simple types create a simple type of type integer
    The attribute which you are binding to value property ;make its type as simple type which you made
    Hope this helps you
    Regards
    Rohit

  • Error message - BSEG-WRBTR enter a numeric value

    Hi,
    I am having a problem with loading data using a abap program that calls RFBIBL00 program and the fb01 Transaction. The process is that the user enters the data in a excel sheet, saves as a tab deliminted txt file. The abap program reads the txt file, does some processing and submits the RFBIBL00 program with the FB01 code. When I check in SM35, it shows on the "incorrect " tab. When you display the log for the process, It is displaying "Formatting error in the field BSEG-WRBTR; see next message" and "Enter a numeric value".  I am not sure where to start looking to try to correct this problem. I am tracing the abap program that submits the RFBIBL00 process and I am not finding where this is occuring. I am new to the ABAP world and I am having a hard time figuring this out. Can someone please let me know if I am proceeding in the right direction or if there is another way of solving this. I am not sure what program is generating the above error messages. If there is more information that is needed, please let me know and I will try to get it for you.
    thanks in advance for the help on this

    Hi,
    There may be two possiblities for this issue.
    1. Incorrect data passed to the field BSEG-WRBTR
    2. Check the Decemial Notation(Menu Path->System->status->Own profile and Defaults Tab). If it is diffrent with the entered amount format, then it will trigger error.
    YOu can run the Bach in the fouground by  choosing fouground radio button option in the Pop up.
    Thanks,
    Ramakrishna

  • In Adobe Acrobat XI Pro, how do I validate a form field so that it's numerical value is less than or

    I have one numerical field named "B," and I need to validate it so that it is less than or equal to the value of another field named "A." I can't figure out how to do that!

    OK, so the custom calculate script for field B could be something like:
    (function () {
        // Get field values as strings
        var sA = getField("A").valueAsString;
        var sC = getField("C").valueAsString;
        var sD = getField("D").valueAsString;
        // Only perform the calculation if all fields are filled
        if (sA && sC && sD) {
            var sum = +sC + sD;
            event.value = sum;
            // Alert the user if the sum is more than A
            if (sum > +sA) {
                app.alert("Error message goes here");
        } else {
            // Blank this field if all fields are not filled in
            event.value = "";
    Instead of (or in addition to) an app.alert popup, you could place this message in a read-only form field, and clear it if there is no error condition.

  • PL/SQL NUMERIC VALUE ERROR

    Hi ,
    We have following code and sending the data through attachnmet its giving the pl/sql numeric value error.
    Please correct me.
    __Code Details:::__
    CREATE OR REPLACE PROCEDURE APPS.print_reports
    IS
    wfile_handle UTL_FILE.file_type;
    lv_file VARCHAR2 (100);
    lv_date VARCHAR2 (20);
    mail_conn UTL_SMTP.connection;
    lv_rep_headers VARCHAR2 (32000);
    p_o_srv_result xxcss_prf_report_pkg.ref_cur_srv_prog;
    lv_str_type XXCSS_PRF_STRING;
    lv_line VARCHAR2 (32767);
    lv_send_to VARCHAR2 (200);
    lv_host_name VARCHAR2 (200) := 'outbound.cisco.com';
    l_vtab CHAR := CHR (9);
    lv_from VARCHAR2 (200) := '[email protected]';
    lv_att_file_name VARCHAR2 (200);
    lv_path VARCHAR2 (200);
    p_request_type VARCHAR2 (1) := 'E';
    p_request_id NUMBER;
    errbuf VARCHAR2 (2000);
    retcode NUMBER;
    crlf VARCHAR2 (2) := CHR (13) || CHR (10);
    lv_line_data Clob;
    lv_clob clob;
    BEGIN
    BEGIN
    SELECT VALUE
    INTO lv_path
    FROM v$parameter
    WHERE NAME = 'utl_file_dir';
    EXCEPTION
    WHEN OTHERS
    THEN
    lv_path := '\tmp';
    END;
    lv_rep_headers :=
    'REGION'
    || CHR (9)
    || 'COUNTRY'
    || CHR (9)
    || 'CUSTOMER NAME'
    || CHR (9)
    || 'ERP CUSTOMER NUMBER'
    || CHR (9)
    || 'PROFILE ID'
    || CHR (9);
    FOR i IN ( SELECT DISTINCT srv_program_id srv_prgm
    FROM xxcss_prf_cust_srv_programs
    ORDER BY srv_program_id ASC)
    LOOP
    lv_rep_headers := lv_rep_headers ||i.srv_prgm || CHR (9);
    END LOOP;
    lv_rep_headers := lv_rep_headers || CHR (13);
    BEGIN
    XXCSS_PRF_REPORT_PKG.offline_daemon (p_request_id,
    p_request_type,
    p_o_srv_result,
    errbuf,
    retcode);
    EXCEPTION
    WHEN OTHERS
    THEN
    DBMS_OUTPUT.PUT_LINE ('Error in Offline');
    END;
    lv_att_file_name := 'Eligibility_reports'||p_request_id||'.xls';
    -- DBMS_OUTPUT.PUT_LINE (lv_rep_headers);
    wfile_handle := UTL_FILE.fopen (lv_path, lv_att_file_name, 'W');
    UTL_FILE.put_line (wfile_handle, lv_rep_headers);
    BEGIN
    LOOP
    FETCH p_o_srv_result INTO lv_str_type;
    EXIT WHEN p_o_srv_result%NOTFOUND;
    lv_line := NULL;
    FOR i IN 1 .. lv_str_type.COUNT
    LOOP
    lv_line := lv_line || lv_str_type (i) || CHR (9);
    END LOOP;
    lv_line := lv_line || CHR (13);
    UTL_FILE.put_line (wfile_handle, lv_line);
    END LOOP;
    lv_str_type.DELETE;
    END;
    UTL_FILE.fclose (wfile_handle);
    BEGIN
    wfile_handle := UTL_FILE.FOPEN (lv_path, lv_att_file_name, 'R');
    -- DBMS_OUTPUT.PUT_LINE ('inside file');
    LOOP
    UTL_FILE.GET_LINE (wfile_handle, lv_line_data,32767);
    -- DBMS_OUTPUT.PUT_LINE (lv_line_data);
    lv_clob := lv_clob || lv_line_data;
    END LOOP;
    UTL_FILE.FCLOSE (wfile_handle);
    EXCEPTION
    WHEN OTHERS
    THEN
    errbuf := sqlerrm;
    UTL_FILE.FCLOSE (wfile_handle); -- close file
    DBMS_OUTPUT.PUT_LINE ('Exception'||errbuf);
    NULL;
    END;
    DBMS_OUTPUT.PUT_LINE ('afterdata');
    --DBMS_OUTPUT.PUT_LINE (lv_line_data);
    SELECT email_id
    INTO lv_send_to
    FROM xxcss_prf_offline_report_tb
    WHERE request_id = p_request_id AND report_type = p_request_type;
    mail_conn := UTL_SMTP.open_connection (lv_host_name, 25);
    UTL_SMTP.Helo (mail_conn, lv_host_name);
    UTL_SMTP.Mail (mail_conn, 'sangrdas');
    UTL_SMTP.Rcpt (mail_conn, lv_send_to);
    UTL_SMTP.OPEN_Data(mail_conn) ;
    DBMS_OUTPUT.PUT_LINE ('Sending Data');
    UTL_SMTP.write_Data (
    Mail_Conn,
    'Date: '
    || TO_CHAR (SYSDATE, 'Dy, DD Mon YYYY hh24:mi:ss')
    || crlf
    || 'From: '
    || lv_from
    || crlf
    || 'Subject: ELIGIILITY Report_'
    || p_request_id
    || crlf
    || 'To: '
    || lv_send_to
    || crlf
    || 'MIME-Version: 1.0'
    || crlf
    || -- Use MIME mail standard
    'Content-Type: multipart/mixed;'
    || crlf
    || ' boundary="-----SECBOUND"'
    || crlf
    || '-------SECBOUND'
    || crlf
    || 'Content-Type: text/plain;'
    || crlf
    || 'Content-Transfer_Encoding: 7bit'
    || crlf
    || 'some message text'
    || crlf
    || -- Message body
    'more message text'
    || crlf
    || '-------SECBOUND'
    || crlf
    || 'Content-Type: text/plain;'
    || crlf
    || ' name="'|| lv_att_file_name||'"'
    || crlf
    || 'Content-Transfer_Encoding: 8bit'
    || crlf
    || 'Content-Disposition: attachment;'
    || crlf
    || ' filename="'
    || lv_att_file_name
    || '"'
    ||crlf
    ||crlf
    ||lv_clob
    || crlf
    ||crlf
    ||crlf
    || '-------SECBOUND');
    UTL_SMTP.CLOSE_Data(mail_conn) ;
    UTL_SMTP.quit (mail_conn);
    DBMS_OUTPUT.PUT_LINE ('After Mail');
    EXCEPTION
    WHEN OTHERS THEN
    errbuf := sqlerrm;
    DBMS_OUTPUT.PUT_LINE ('ERROR Sending Data'||errbuf);
    ROLLBACK;
    END;
    /

    Yet again, opening a new thread for an existing issue...
    Need help in UTL file
    Same old, same old...
    need a report code
    need to create the header dynamically for a report
    Would have thought you'd get the idea of posting on the forums by now.

Maybe you are looking for

  • Reports output not coming in Excel

    Hello everyone, Here Application is 11.5.10.2 We are not getting output in EXCEL format for reports. We r getting output in PDF and all.... Report is completed successfully............ Please do need full, It's urgent... Thanks,

  • Purchase Requisitions from Maintenance

    Dear Friends, We are implimenting Plant Maintenace and all other modules. Purchase requisitions are created with Maintenance Order automatically, and Purchase Requisitions will be created with MRP also. I want the Release strategy for MRP created PRs

  • Report linking Oppty - Account-Contacts

    Hello there, I willing to create a report which can show all the contacts having at least one "closed/won" opportunity in the last two years, but I'm having very much trouble linking opportunities to all the contacts since as you probably know, I onl

  • Why does my Photos folder have this inside?

    So, to cut this short, I plugged my iPod in today and BAM! 6 Local Disks. What are these in my photos file? I ran a virus scan in there and no negative results were returned. Any help would be highly appreciated Thanks!

  • Identify a specific Safari window

    I am trying to write a script to screencapture or print a specific Safari window. I have 6 monitors, 1 monitor is always devoted to one Safari window that displays the same website. Other Safari windows are open as well, in addition to other applicat