To Check Value in Range

I have three columns in a table with data type varchar2
one in of min_range and other is of max_range both are defined user will enter only the result value against a test
now i want to check that result value
firstly if number then must be in min and max range otherwise change the record visual attribute.If the result entered is character then no check

One way to do it would be to test if you can convert the value to a number,
use the pl/sql block example as a guide,
DECLARE
FUNCTION Is_Number
(vchar_value VARCHAR2)
RETURN BOOLEAN IS
tst_num NUMBER;
BEGIN
tst_num := To_Number (vchar_value);
RETURN True;
EXCEPTION
WHEN VALUE_ERROR THEN
RETURN False;
END;
BEGIN
IF Is_Number ('45') THEN
dbms_output.put_line ('Value is a number');
END IF;
IF NOT Is_Number ('ABC') THEN
dbms_output.put_line ('Value is not a number');
END IF;
END;

Similar Messages

  • Timestamp data type on S[range C on E] constant value-based range windows

    Hello,
    My questiong is about how can we use timestamp value on S[range C on E] constant value-based range windows.
    I have a LotEvent which i should collect and sum lastQty data for last ten minutes of market time (sendDate)
    A normal [range 600] query does not work for me because i would like to use the exact time which data has been generated by the market (sendDate).
    Here is the event;
    public class LotEvent{
         private Double totalQty;
         private float lastQty;
         private String symbol;
         private String messageType;
         private Integer dataInterval;
         private String sendDate;
    send date is always in "MM-dd-yyyy HH:mm:ss" format.
    I have tried to use the following query but this gives an error;
    Invalid statement: "select symbol, sum(lastQty) as lastQty, 10 AS dataInterval
    +from lotInputChannel [range INTERVAL "0 0:0:15.0" DAY TO SECOND on >>sendDate<<]+
    group by symbol"
    Cause: Datatype char is not valid for value based windows
    Action: Use a valid datatype for value based windows>
    Here is the CQL;
    <?xml version="1.0" encoding="UTF-8"?>
    <wlevs:config xmlns:wlevs="http://www.bea.com/ns/wlevs/config/application">
    <processor>
    <name>lotProcTenMin</name>
    <rules>
         <query id="tenMin"> <![CDATA[select symbol, sum(lastQty) as lastQty, 10 AS dataInterval 
                from lotInputChannel [range INTERVAL "0 00:10:00.0" DAY TO SECOND on sendDate]
    group by symbol]]> </query>
    </rules>
    </processor>
    </wlevs:config>
    i have tried this cql after changing the sendDate data type to long which is the time in milliseconds value but it did not work.
    select symbol, sum(lastQty) as lastQty, 10 AS dataInterval
    from lotInputChannel [range INTERVAL "0 00:10:00.0" DAY TO SECOND on to_timestamp(sendDate)]
    group by symbol
    The query above does not work also when sendDate is a String in "MM-dd-yyyy HH:mm:ss" format
    At last i tried the following query with sendDate as time in milliseconds (long) value. It works! but i still would like to know how to use timestamp in S[range C on E] queries
    select symbol, sum(lastQty) as lastQty, 10 AS dataInterval
    from lotInputChannel [range *600000* on sendDate]
    group by symbol
    public class LotEvent{
         private Double totalQty;
         private float lastQty;
         private String symbol;
         private String messageType;
         private Integer dataInterval;
         private long sendDate;
    Could anybody please help me with this issue?
    Edited by: user8830791 on 01-Aug-2011 06:39

    It seems that you should configure the channel "lotInputChannel" as an application timestamped channel.
    You can do that as follows -
    - Have "sendDate" as a long and let its unit be milliseconds
    - Use the following child elements of <channel> for the "lotInputChannel"
    <wlevs:application-timestamped is-total-order="true">
    <wlevs:expression>sendDate*1000*1000</wlevs:expression>
    </wlevs:application-timestamped>
    The multiplication by 10^6 is required since the units need to be converted into nanos
    With this, you could use the query -
    select symbol, sum(lastQty) as lastQty, 10 AS dataInterval
    from lotInputChannel [range 10 minutes]
    group by symbol
    Of course, for the above to work, a requirement is that the value of "sendDate" is non-decreasing.
    That is if e1 is before e2 in the "lotInputChannel" then e1.sendDate <= e2.sendDate
    Edited by: Anand Srinivasan on Aug 2, 2011 6:57 AM

  • What is KCV (Key Check Value) in 3DES used for?

    Hi Friends..
    I want to know what is KCV (Key Check Value) used for?..
    i found that 3DES operation (2Keys length or 3Keys length) sometimes needs KCV (Key Check Value)..
    As far as i know the KCV itself computed as Follows :
    3DES(Keys, IV(all zeroes), Data (8byte zeroes)
    Please correct me if i'm wrong..
    Thanks

    Leonardo Carreira wrote:
    sabre150 wrote:
    Leonardo Carreira wrote:
    Could you suggest me what is the good book for "learning the concept of cryptography"?..Errr ... I thought I had done that!Yes you're right, you had suggested the book for me..
    And i don't found the KCV (Key Check Value) usage in the book..
    So, i ask this question, sorry if my question is sounds boring to you, sorry for this inconvenience.. :(
    thanksKCV has at least two different meanings. I suspect you are interested in the one outlined in http://www.cryptographyworld.com/key.htm.

  • FI13 - 'Check' value in SU24 appearing in PG

    Hi Experts,
    FI13 tcode has been included in a role. We find that auth. object S_TABU_DIS has 'CHECK" value in check indicator(SU24). But in PG S_TABU_DIS value is appearing with values 02,03 for the activity field.
    My query is eventhough the value of auth. object S_TABU_DIS is maintained as check in SU24, how is it appearing in PG. Please provide me details of the logic behind it.
    Version: SAP ECC 5.0
    Thanks for your time in advance.
    Regards,
    Nagendran

    Hi,
    Transaction FI13 is a parameter transaction which calls transaction SM34, which is used to maintain tables. Object S_TABU_DIS is a checked (value yes) for SM34. Hence it is appearing in the role. Also that is the reason it is not showing any values in authorization group field. If you would like to use FI13, then you should have object S_TABU_DIS with below values
    Activities: 02,03
    Authorization group: VC
    Please goto transaction SE93 and click on display. You can see the details for FI13 which has been using transaction SM34.
    Regards,
    Gowrinadh

  • How check the number range buffers in bw..

    can any one tell me the procedure...
    how to  check the number range buffers in sap bw,,,,can any one help me on this???
    regards

    Please follow the steps mentioned below for checking the number ranges:
    TCODE: /nse37
    FUNCTION MODULE: RSD_CUBE_GET
    Then click F8
    From there I_INFOCUBE : Cube name(Here we can give the cube names from /nrsa1(click on infoprovider on leftside menu…)
    I_INFOCUBE                      Cubename
    I_OBJVERS                       A
    I_BYPASS_BUFFER                 x
    I_WITH_ATR_NAV
    Click on F8
    In Export Parameters : select below one
    E_T_DIME
    There we will get the Time stamp and number range
    Regards.
    Message was edited by:
            cnu babu

  • Bad check value found during dbv on Datafiles

    Hi,
    We just received new DB, that return a "Bad check value found during dbv" on DBVerify.
    So, we can Open & Use this DB... perhaps until crash if we use the "bad block", but we can't save it by Rman (ORA-19566: exceeded limit of 0 corrupt blocks for file xxx) !
    And best thing is... Previous DB owner don't have any save (Rman or other) of this DB !!!
    Are there solution(s) about this problem... or this DB is definitively dead ?
    Sorry for my english,
    Thank for your help,
    J Sourti.

    Hi;
    What is DB version?
    Please see below note(also referance part) and below link which at least show u some way
    Rman Reports An Ora-19566: Exceeded Limit Of 0 Corrupt Blocks From Backup [ID 457422.1]
    http://oraclespin.wordpress.com/2009/07/03/how-to-find-and-fix-block-corruption-using-rman/
    Regard
    Helios

  • How to Access Radiobutton Check Value

    Hi all,
    I'm using Oracle 10g Forms Developer and I want to know how to access radio button check value, that means how to know that the current radio button is checked or not. Thanks in advance

    you assign each button the representing value in the properties.
    So you can just check if the radiogroup-item has the value you assigned the button, something like:
    IF :BLOCK.RADIOBUTTONITEM='A' THEN
    ...

  • Check value from Backend and update SC

    Hi,
    I am using SRM 5.0 and I have an requirement where I need to check value of SC or PO with backend system and accordingly update one custom field in SC/PO .
    Can anybody let me know exact place to perform this coding ?.
    Thanks,
    Sachin

    To update SC/PO at transaction time, you should use BADI "BBP_DOC_CHANGE_BADI" (Vadim is right). Indeed this BADI is called very often. It is recommended to filter your code using table sy if you are executing complex coding or remote call. You can use sy-ucomm, sy-tcode...
    Try to identify the right moment to call your remote function and check sy table in debugging.
    Axel

  • How check value befor commit my form

    hi master
    sir
    how check value befor commit my form if that value right than commit otherwise show message box and not save
    please give me idea
    thanking you
    aamir

    Have you not tried using When-Validate-Item Trigger.
    Like if i have an Item Which can only take dates between sysdate and sysdate-3 your code in when-validate of the item should be
    If :BlockName.ItemName NOT BETWEEN SYSDATE-3 AND SYSDATE THEN
    MESSAGE('Pleaes Enter valid date);
    RAISE FORM_TRIGGER_FAILURE;
    END IF;
    This will fire, and commit will fail.

  • How to check the default checked  value for radio button on jsp for struts

    Hello , I just want to check the default checked value in JSP for a radio button, how can i do that?
    <html:radio property="sale" value="permanent" style="vertical-align: middle;">Permanent</html:radio>
    <html:radio property="sale" value="temporary" style="vertical-align: middle;">Temporary</html:radio>

    you can set the default value for property ( which you want to default selected when the form is first loaded) in reset method of the form.
    <html:radio property="sale" value="permanent" style="vertical-align: middle;">Permanent</html:radio>
    <html:radio property="sale" value="temporary" style="vertical-align: middle;">Temporary</html:radio>
    In the above case you can write the code as follows in the perticular form of this jsp.
    public void reset(ActionMapping mapping, HttpServletRequest request) {
    super.reset(mapping, request);
         sale = "permanent";
    This will show the first check box default selected when the first time the page is loaded.

  • How to get check value in DB based on java

    hi,
    anybody know how to get check value in DB based on java?
    TQ

    This should be a custom java class containing that method.
    Try on java or jdbc forum - Java Database Connectivity (JDBC) , Java Programming

  • Generating check value for put key

    hi
    in globalPlatform doesn't exist anything about check value for put key command.
    how can i generate it and change initial key for my java card?

    s.fallahdoost wrote:hello
    in other topic, i saw that you used these commands
    for put-key:
    cm> set-key 2/1/DES-ECB/ffeeddccbbaa99887766554433221100 2/2/DES-ECB/ffeeddccbbaa99887766554433221100 2/3/DES-ECB/ffeeddccbbaa99887766554433221100
    cm> put-keyset 2
    *=> 84 D8 00 81 4B 02 80 10 AE 25 9D AE 8A 7F 23 37 ....K....%....#7*
    *7F CF AD 42 5C B8 C3 EC 03 F3 9C 09 80 10 AE 25 ...B\..........%*
    *9D AE 8A 7F 23 37 7F CF AD 42 5C B8 C3 EC 03 F3 ....#7...B\.....*
    *9C 09 80 10 AE 25 9D AE 8A 7F 23 37 7F CF AD 42 .....%....#7...B*
    *5C B8 C3 EC 03 F3 9C 09 69 54 47 5D 25 8A AA 36 \.......iTG]%..6*
    *00 .*
    *(259100 usec)*
    *<= 02 F3 9C 09 F3 9C 09 F3 9C 09 90 00 ............*
    Status: No Error
    i know that AE 25 9D AE 8A 7F 23 37 7F CF AD 42 5C B8 C3 EC
    is your new key and F3 9C 09 is the first 3 bytes of tripleDES with key
    ffeeddccbbaa99887766554433221100.
    i have a question:
    what is ffeeddccbbaa99887766554433221100?!!
    how can i calculate it?ffee..00 is the plain text key. Sensitive data encryption is required for the 3 CM keys in the PUT KEY command. I first set off-card the keys I want to be included in the PUT KEY command, and JCOP Tools encrypts it with the DEK key of the current secure channel session. On-card the first the C_MAC is validated, then the keys are decrypted and compared to the key check value.

  • Error check for multiple ranges input

    Hi,
    I have coded a report with the following select options:
    SELECT-OPTIONS:
       S_PONUM FOR EKKO-EBELN NO INTERVALS,
       S_PODAT FOR EKKO-BEDAT NO-EXTENSION,
       S_LCNUM FOR EIKP-VORNU NO-EXTENSION NO INTERVALS,
       S_VENDR FOR EKKO-LIFNR NO-EXTENSION NO INTERVALS.
    I want that a check should be applied at the selection screen level that at least one field should contain a value, i.e. report cannot be run with all blank selection fields.
    I am using this code:
    AT SELECTION-SCREEN.
    IF S_PONUM-LOW IS INITIAL AND
        S_PODAT-LOW IS INITIAL AND
        S_LCNUM-LOW IS INITIAL AND
        S_VENDR-LOW IS INITIAL.
        MESSAGE I007(ZSH_MSGC) WITH 'All selection fields cannot be blank'.
    ENDIF.
    This works fine, but the problem is that when entering multiple ranges for S_PONUM, when the button on the right of the field is clicked to input range values the message pops up. I want that the check should be applied on execute (F8). Any suggestions? Help is appreciated.
    Regards,

    Hello,
    check the sy-ucomm when the button on the right of the field is clicked keep the condition which i have kept it.
    before the if statement keep this condition also
    SELECT-OPTIONS:
    S_PONUM FOR EKKO-EBELN NO INTERVALS,
    S_PODAT FOR EKKO-BEDAT NO-EXTENSION,
    S_LCNUM FOR EIKP-VORNU NO-EXTENSION NO INTERVALS,
    S_VENDR FOR EKKO-LIFNR NO-EXTENSION NO INTERVALS.
    AT SELECTION-SCREEN.
    if sy-ucomm ne 'find the sy-ucomm'.
    IF S_PONUM-LOW IS INITIAL AND
    S_PODAT-LOW IS INITIAL AND
    S_LCNUM-LOW IS INITIAL AND
    S_VENDR-LOW IS INITIAL.
    MESSAGE  'All selection fields cannot be blank' type 'E'.
    ENDIF.
    endif.
    Edited by: Santosh Marupally on Apr 22, 2009 9:41 AM

  • FM to check values in select option

    Hi Experts ,
    I want to compare values entered in select option with certain constant values. Is there any FM which will do this?
    Thanks & Regards ,
    Jigar Thakkar

    I believe that there is no such FM. You need to build a range for your constant values and then compare your select option with the range build for constants.
    Eg.
    select-options: s_werks for t001w-werks.
    ranges r_werks for t001-werks.
    r_werks-sign = 'I'.
    r_werks-option = 'EQ'.
    r_werks-low = '2101'.   "Pass the constant value.
    append r_werks.         "Range built for one entry 2101. Similarly append further constant values.
    *Check if select option contains any of the constant values.
    if s_werks in r_werks.
    * Select-options contains value as defined in range
    else.
    * No matching value found.
    endif.

  • Check value in select-options

    Hello,
    how can i check, if a certain value is in a select-option range,
    f.e. check if value '1000' is in s_matnr (s_matnr for mara-matnr)
    Thanks,
    TomSd

    Hi Thomas Strehle ,
    Do the checking in AT SELECTION SCREEN.
    S_MATNR will have two fields LOW and HIGH.
    HIGH value wont accept if the low value is empty.
    So Check with the low value.
    select single * from mara where matnr in s_matnr
    this will take the range if both the low and high value is given
    else if only low is given "=" is taken
    else if no value is given it will fetch all the values
    Or
    select single * from mara where matnr = s_matnr-low
    this will fetch only if the value in low is present.
    for all other option it wont fetch.
    choose any according to your requirement.
    validation has to be done in  AT SELECTION SCREEN.
    if you do it in other events and had to display a error message.
    It wont allow the user to correct the entry and rerun the program.

Maybe you are looking for

  • I am trying to move my Acrobat 9 Pro Extended  from my older HP Win7 Pro notebook to my new HP Win 7

    I am trying to move my Acrobat 9 Pro Extended from my older HP Win7 Pro notebook to my new HP Win 7 Pro notebook. This should be WAY easy, and it's not. Sofware downloaded from MS/HP after new noteboook was safely home. Used Microsoft transfersoftwar

  • Where can I find PDF Help files for CS5?

    I have CS5 Design Standard ( without extended Photoshop) and I need to get the PDF help files for the component applications.  I have tried entering CS5 Help Files and variations of that theme in the search box here at Adobe forums  and get many thin

  • Mail Merge Possibilities

    Is it possible to have a mail merge with multiple different addresses but with two turned clockwise like the one in the picture?  is There maybe a script that could do something?

  • I can't find OPatch.exe

    I will plan to install CPU Patch on Oracle 9.2.0.7 but I can't find opatch.exe and not OPatch folder on any drive. What's wrong and how to fix problem? Thank you

  • 59 Days and counting and Photo Stream still grayed out in iCloud C

    59 Days and counting and Photo Stream still grayed out in iCloud CP since problem first discussed with Apple. No help, just reported to software engineers for investigation. Almost two months ago! So much forApples' superior products and customer ser