How to check value is numeric or not

hi how to check whether a value is numeric or not.
example.  data : x type n.
          x = 12345.
Now how to check whether X contains numeric value or not.

Hi,
     If your type is 'N' there is no way that 'X' can have any value apart for numberics (i.e. 0 - 9).
You can also check that as follows.
Data: num_list(10) type c value '0123456789',
      x type n.
X = '12345'.
This is more useful if your X is of type C.
if X CO num_list.
Its only numeric
else.
its contains non numeric
endif.
Regards,
Sesh

Similar Messages

  • How to check table is creating or not

    Hi,
    I am creating only one table by running a table creation script(table.sql) which contain 366 partition.but I dont know whether table is creating or not.it is taking long time,sometimes I feel like script is hanging.even before running the script I have even spooled but spool file shows nothing. so how to check table is creating or not from background? can anyone please let me know abt this.this is bit urgent
    sql>spool table.log
    sql>@table_partition.sql

    hi,
    I am running the script table_partition which consist of 366 partition and 31 sub partition but the script is hanging.there is no hint in alert log file or anything wat might be the reason is it because of extent size? as extent size for this tablespace where table has to be create is 1mb,wat i suspect is do i need to set for higher value inorder to avoid this?
    with regards;
    Boo

  • How to check internal table sorted or not

    Hi all
    I need to check internal table sorted or not which is without header line and having only one field and six values. please let me know how to check it is sorted or not because i need to display message if it is not sorted.
    thanks,
    Minal

    Hi Minal,
    Go through  this info.
    Sorted tables
    This is the most appropriate type if you need a table which is sorted as you fill it. You fill sorted tables using the INSERT statement. Entries are inserted according to the sort sequence defined through the table key. Any illegal entries are recognized as soon as you try to add them to the table. The response time for key access is logarithmically proportional to the number of table entries, since the system always uses a binary search. Sorted tables are particularly useful for partially sequential processing in a LOOP if you specify the beginning of the table key in the WHERE condition.
    Stable sort
    The option
    SORT <itab> ... STABLE.
    allows you to perform a stable sort, that is, the relative sequence of lines that are unchanged by the sort is not changed. If you do not use the STABLE option, the sort sequence is not preserved. If you sort a table several times by the same key, the sequence of the table entries will change in each sort. However, a stable sort takes longer than an unstable sort.
    Examples
    DATA: BEGIN OF LINE,
            LAND(3)  TYPE C,
            NAME(10) TYPE C,
            AGE      TYPE I,
            WEIGHT   TYPE P DECIMALS 2,
          END OF LINE.
    DATA ITAB LIKE STANDARD TABLE OF LINE WITH NON-UNIQUE KEY LAND.
    LINE-LAND = 'G'.   LINE-NAME   = 'Hans'.
    LINE-AGE  = 20.    LINE-WEIGHT = '80.00'.
    APPEND LINE TO ITAB.
    LINE-LAND = 'USA'. LINE-NAME   = 'Nancy'.
    LINE-AGE  = 35.    LINE-WEIGHT = '45.00'.
    APPEND LINE TO ITAB.
    LINE-LAND = 'USA'. LINE-NAME   = 'Howard'.
    LINE-AGE  = 40.    LINE-WEIGHT = '95.00'.
    APPEND LINE TO ITAB.
    LINE-LAND = 'GB'.  LINE-NAME   = 'Jenny'.
    LINE-AGE  = 18.    LINE-WEIGHT = '50.00'.
    APPEND LINE TO ITAB.
    LINE-LAND = 'F'.   LINE-NAME   = 'Michele'.
    LINE-AGE  = 30.    LINE-WEIGHT = '60.00'.
    APPEND LINE TO ITAB.
    LINE-LAND = 'G'.   LINE-NAME   = 'Karl'.
    LINE-AGE  = 60.    LINE-WEIGHT = '75.00'.
    APPEND LINE TO ITAB.
    PERFORM LOOP_AT_ITAB.
    SORT ITAB.
    PERFORM LOOP_AT_ITAB.
    SORT ITAB.
    PERFORM LOOP_AT_ITAB.
    SORT ITAB STABLE.
    PERFORM LOOP_AT_ITAB.
    SORT ITAB DESCENDING BY LAND WEIGHT ASCENDING.
    PERFORM LOOP_AT_ITAB.
    FORM LOOP_AT_ITAB.
      LOOP AT ITAB INTO LINE.
        WRITE: / LINE-LAND, LINE-NAME, LINE-AGE, LINE-WEIGHT.
      ENDLOOP.
      SKIP.
    ENDFORM.
    ************rewords some points if it is helpful.
    Rgds,
    P.Naganjana Reddy

  • How to check Reconcilliation has happened or not for a payment document

    Hi,
    How to check Reconcilliation has happened or not for a payment document? Payment doc ABCDEF was created on 2nd. Now i am not sure whethr RECON has happend ot not
    Please help.

    Dear,
    If you have made payment to vendor and want to know whether reconciliation happened or not then check if this document exist in table BSIK then reconciliation has not been done.
    Regards,
    Chintan Joshi.

  • How to check table is NULL or not when a form load?

    How to check table is NULL or not when a form load?
    I want to make the form when it load it check the data in table, if there are no data in table other form will be load.
    Sorry for bad English... 

    Maybe you can do this in form1's Form_Open event:
    if dcount("*", "table1") = 0 then
      Cancel = True
      Docmd.Openform "form2"
    end if
    -Tom. Microsoft Access MVP

  • How to check one table exist or not in SAP

    Hi, Gurus:
    How to check one table exist or not in the SAP.
    Thanks,

    Hi,
    Query the table DD02L..
    Select single * from DD02L where tabname = 'Your table name'
                          AND TABCLASS = 'TRANSP'.  " For transparent tables.
    Thanks
    Naren

  • How to check oracle properly installed or not?

    Hello Friends,
    How to check oracle properly installed or not. cause during installation time the person who installed faced many problems. we have RISK base IBM p5 Series server and Oracle 10g RAC.
    i want to check installation made properly or not.
    Thanks,
    Nikunj Patel

    Installation for RAC environments means you are not only talking about one single installation, but several installations, and the number of installations and checking processes depend on factors such as the clusterware you are using, if you are using the Oracle clusterware or the proprietary clusterware, if you are using a separate oracle home to install the ASM or if you are using the same oracle home for both, the ASM and the RDBMS.
    First you must ensure you have installed all prerequisites according to your platform, i.e. patches, packages, kernel parameters, etc. which are listed at the install guide corresponding to your platform. Then you should use the cluvfy (cluster verifier tool) to check if the different install phases are properly installed
    The most critical and most of the times, problematic installation phase is the clusterware. So you should specify if you installed the Oracle clusterware or the proprietary clusterware. In a RAC environment if your clusterware is not properly installed, most probably you won't have a running RAC, so if your environment is functional there you may have high probabilities that it is OK, but to make sure, launch the cluvfy tool.
    The cluvfy tool verifies the process since the beginning and it ensures your environment meets the required minimum requirements to be at an operational level, it checks the pre/post install phases for the clusterware, pre/post install of the rdbms, and it is launched from the OS. It can be obtained as a standalone product or you can use the one found at the clusterware Oracle Home. For further references on this tool I suggest you to read this
    Oracle® Database Oracle Clusterware and Oracle Real Application Clusters Installation Guide
    10g Release 2 (10.2) for AIX
    Part Number B14201-04
    ~ Madrid

  • Check if an item's value is numeric or not

    Hello all,
    does anybody know if there exists a funtion in PLSQL to check wether a string is numeric or not? How can this get implemented?
    regards patrick

    Thanks Peter, I was not asumming that null was a number...
    A got a little modification to the code, that considers null as number (if you want so, if not... just replace "length(nvl(strTMP, 0))" with length(strTMP) ) and accept the decimals and negatives as numbers...
    DECLARE
    FUNCTION is_number(str IN VARCHAR2)
    RETURN BOOLEAN IS
    dummy NUMBER;
    strTMP varchar(100);
    BEGIN
    strTMP := translate(str, '1-.,', '1');
    --Validating only digits
    for i in 1..length(nvl(strTMP, 0)) loop
    dummy := TO_NUMBER(substr(strTMP,i,1));
    end loop;
    --Enforcing number meaning, here 1.2.3 and -126-3 will not pass
    dummy := TO_NUMBER(str);
    RETURN TRUE;
    EXCEPTION
    WHEN VALUE_ERROR
    THEN
    RETURN FALSE;
    END is_number;
    BEGIN
    IF is_number('a') THEN
    dbms_output.put_line('a is a number');
    else
    dbms_output.put_line('a is not a number');
    END IF;
    IF is_number('343E3') THEN
    dbms_output.put_line('343E3 is a number');
    else
    dbms_output.put_line('343E3 is not a number');
    END IF;
    IF is_number(null) THEN
    dbms_output.put_line('null is a number');
    else
    dbms_output.put_line('null is not a number');
    END IF;
    IF is_number(100) THEN
    dbms_output.put_line('100 is a number');
    else
    dbms_output.put_line('100 is not a number');
    END IF;
    IF is_number('-1234') THEN
    dbms_output.put_line('-1234 is a number');
    else
    dbms_output.put_line('-1234 is not a number');
    END IF;
    IF is_number('12.34') THEN
    dbms_output.put_line('12.34 is a number');
    else
    dbms_output.put_line('12.34 is not a number');
    END IF;
    IF is_number('1.2.3.4') THEN
    dbms_output.put_line('1.2.3.4 is a number');
    else
    dbms_output.put_line('1.2.3.4 is not a number');
    END IF;
    IF is_number('-12-3.4') THEN
    dbms_output.put_line('-12-3.4 is a number');
    else
    dbms_output.put_line('-12-3.4 is not a number');
    END IF;
    END;
    Just a little bit more work...
    Regards,
    Mike

  • How to check program is running or not

    Hi,
    Is it possible to check whether a program is running or not?
    I know when you try to compile a package which is running, oracle does not allow you compile it, it hangs. That is, somehow, Oracle knows the program is running. How can we check this information?
    Suppose procedure below. If i ran it in one session, how can check that procedure p is running in other session?
    I searched the forum. There is one( checking if a package procedure is already running ) thread but noone has replied.
    Thanks....
    SQL> DROP TABLE T;
    Table dropped
    SQL> CREATE TABLE T AS SELECT DUMMY D FROM DUAL;
    Table created
    SQL> CREATE OR REPLACE PROCEDURE p IS
      2    s VARCHAR2(12);
      3  BEGIN
      4    SELECT d INTO s FROM t;
      5    LOOP
      6      EXIT WHEN s = 'Y';
      7      SELECT d INTO s FROM t;
      8    END LOOP;
      9  END p;
    10  /
    Procedure created
    SQL> exec p;

    I found the answer from another thread.( Package Compilation Hangs )
    Answer is : http://www.ixora.com.au/scripts/sql/executing_packages.sql

  • How to check patch level applied or not?

    how can i check that bellow patches are applied or not as mentioned for patch no 7427746.
    - FA.M mini-pack or later
    or
    - FIN_PF.E or later
    and
    -ATG H RUP4() or higher
    thanks

    Hi;
    how can i check that bellow patches are applied or not as mentioned for patch no 7427746.
    - FA.M mini-pack or later
    or
    - FIN_PF.E or later
    and
    -ATG H RUP4() or higherPlease check :
    - How to check which Techstack patchsets have been applied [390864.1 ]
    Regard
    Helios

  • How to check mail already read or not?

    Hi everyone
    I am developing an application using javamail api.
    I have no idea how to check mail is already read or answered or seen using javamail api.
    I need to fetch new mail every time. I used DELETE flag ,its working fine but it also delete mail permanently from inbox.
    I want to fetch new mail and already fetched mail is also reside in inbox. but not fetched next time.
    Pls help me.

    Either I'm not understanding you, or you're not understanding JavaMail.
    First, the POP3 protocol supports no permanent flags, as explained in
    http://java.sun.com/products/javamail/javadocs/com/sun/mail/pop3/package-summary.html
    You can set flags on messages, but they won't persist after you close the folder.
    If you set the DELETED flag and close the folder and expunged deleted messages,
    the messages are gone for good.
    That's not a JavaMail limitation, that's a POP3 protocol limitation.
    Again, as explained in the link above, to determine which messages are new you'll
    need to keep some state in your application about which messages you've seen
    and compare that state with the current state of the INBOX. You can use the POP3
    specific UIDL command to help with this.
    Does that help?

  • How to check oracle is running or not

    Hi,
    Can any one help me the command to check whether oracle is running or not, in UNIX flatform.How to check the Disk+Work proess is running or not.

    Option1 :Logon to SAPDBA...U will be able to see whether Oracle is running or not.
    Option 2:
    Sqlplus /nolog;
    connect / as sysdba;
    startup;
    If it is already running: you will get msg that Oracle is already running
    Oprion 3: ps -eaf|grep ora
    to determine whether disp+work is running or not:
    Option 1: ps -eaf|grep sap
    Option 2: dpmon pf = <path of instance profile>
    Reward Points if helpful!

  • How to check Category is filled or not in Service ticket?

    I have requirement to check the category field (CAT_GUID) is filled with value or not.
    I would like to check this category field in the Badi zOrderSave of service ticket.
    How I can accomplish this issue?
    Your reply is appreciated.
    Banu

    Hi Banu,
    I understood that you have to check Category field.
    Please, "se"nd m"e an "e"mail" with a print screen highlighting the information that u need.
    caiqueescaler hotmail com
    Regards,
    Caíque Escaler
    Edited by: Caíque Escaler on Jun 23, 2010 8:34 PM

  • How to check this is  sequenses or not, and what a best way remove item

    Hi guys, try to rename sequence in after effect, but i don't know how i can get type of footege(sequence or just a one file), also how a get numbers of frame from sequence, because in future i need do loop for rename each file in this sequence and then update path(with single file i do path update with CurenItemInProject.reload(path to my renamed file), but if i do that with sequence, AE rename first frame of sequence and then replace my sequence in project on this renamed first frame), or maybe some one know a better way to rename sequences files?
    also i need remove items from project, and i only know names of nulls and compositions i try do removing like this
    on start of my script i create nuls and precompose(precomposes have dynamic names, nulls is always same)
    var precomposed_for_script = myComp.layers.precompose(preArray,precomp_name,true); //create one precompose
    var precompose_inside_created_precompose=precomposed_for_script.layers.precompose(array_insid e_precompose,precomp_name+"_inside_created_precompose",true); //create second precompose
    on end of the script i try delete my temp nulls and precompose by code below, and get error
    for (var clean = app.project.numItems; clean>= 1; clean--)
                                    var currentItem_for_deleting = app.project.item(clean);
    if ((currentItem_for_deleting.name == precomposed_for_script.name) || (currentItem_for_deleting.name == "nullname1") ||(currentItem_for_deleting.name ==precompose_inside_created_precompose.name)||(currentItem_for_deleting.name =="nullname1"))
                                          currentItem_for_deleting.remove();

    Hi zipkiev,
    If you want to check if something is a sequence you can use:
    if(object instanceof CompItem) {
         //do what you need to do
    Also, you would probably never need this, but in the event that you're using inheritance and object-oriented programming (which if you're not, please disregard), you may also want to add this check:
    object.__proto__.constructor.name == "CompItem"
    Now, as far as sorting...unfortunately when sorting string values, "name10.jpeg" comes before "name2.jpg" mainly because it evaluates the digit "1" and "0" separately (not as "10").  However, you can implement your own sort function and pass it to your array.sort().  Here is some background on the sort function and doing your own custom sort:  JavaScript Array sort() Method
    The basics behind it are the sort function is passed 2 values, a and b.  If a comes before b, the sort function must return a negative number.  If b comes before a, the sort function returns a positive number. And if a and b are equal, then the sort function returns zero.
    So in your case, it could be implemented like this:
    var words = ["c:\\name1.jpg", "c:\\name2.jpg", "c:\\name3.jpg", "c:\\name4.jpg", "c:\\name5.jpg", "c:\\name6.jpg", "c:\\name7.jpg", "c:\\name8.jpg", "c:\\name9.jpg", "c:\\name10.jpg", "c:\\name11.jpg"];
    //This regular expression looks for zero or more characters, followed by 1 or more digits, followed by zero or more characters.
    var digitRegExp = /.*?(\d+).*?/;
    var sortFunc = function(a, b) {
         //extract the number portion of the string
         var aResults = digitRegExp.exec(a);
         var bResults = digitRegExp.exec(b);
         //with regular expression results, the first item in the array is the original string
         //It is then followed by any capture groups in order.
         //You MAY need to put error checking here in the case where the regular expression does not match and no results are found.
         var num1 = aResults[1];
         var num2 = bResults[1];
         return num1-num2;
    words.sort(sortFunc);
    You may need to play with the way you extract the digits from the string name as there might be a pattern you always use.  But hopefully this points you in the right direction.
    Enjoy!
    Calvin

  • How to check if a system is not down??

    Hi All,
    I have a requirement in which i have to call a RFC, from a report, which resides in a different system. if the destination system is down at that moment of time then my report program gives short dump.
    Please suggest me.. if there is any way or standard function module or anything of the kind to check if the destination system is not down.. so that i may give error message instead of calling the RFC and getting the short dump.
    Thanks in advance,
    Shradhanjali

    Hello Maen,
    Nothing wrong with RFC_PING My point is why use it unnecessarily!
    Ofcourse if you've more than one RFM calls to the same RFC destination then using RFC_PING to check the connectivity makes sense. But if you've one RFM call you can check the connectivity in the RFM call itself.
    Something like this:
    CALL FUNCTION 'RFC_PING'
      DESTINATION 'ZTESTSDN'
      EXCEPTIONS
        system_failure        = 1  MESSAGE v_msg
        communication_failure = 2  MESSAGE v_msg.
    IF sy-subrc NE 0.
      MESSAGE 'Cannot Connect to the Destination' TYPE 'E'.
    ENDIF.
    * Call the RFMs only if the RFC_PING succeeds
    CALL FUNCTION 'Z_TEST_RFC1' DESTINATION 'ZTESTSDN'.
    CALL FUNCTION 'Z_TEST_RFC2' DESTINATION 'ZTESTSDN'.
    For single calls:
    CALL FUNCTION 'Z_TEST_RFC1'
      DESTINATION 'ZTESTSDN'
      EXCEPTIONS
        system_failure        = 1  MESSAGE v_msg
        communication_failure = 2  MESSAGE v_msg.
    IF sy-subrc NE 0.
      MESSAGE 'Cannot Connect to the Destination' TYPE 'E'.
    ENDIF.
    Anyway SAP recommends to use these predefined RFC Exceptions for every RFM call. A quote from the SAP documentation:
    We strongly recommend that you assign a return value to both these exceptions for every RFC, and that you handle this return value, as otherwise a runtime error will occur in the exception situations in question.
    Hope i'm clear.
    BR,
    Suhas

Maybe you are looking for