How to check the validation at data base level as well as current user ente

Dear all
i have creation page in that item code will not enter the duplicate values
in that creation page contains advanced table
user will click on create 15 blank records using add another row
suppose in first row user will enter LAPTOP assume this item code
in this case i need to raise exception through databse level
in second row also user enter LAPTOP1 in this case exception will not raise becaause data is not there at databse
in third row user will enter LAPTOP1 in this case item is not there in data base but it is there in second row in this case
i need to raise exception
how to achieve this
Thanks in Advance
Sreekanth

You can validate this in form submission.
1. Call a method in AMImpl.java
2. loop the ViewObjects and check the values
3. If you find a match, throw the error
--Prasanna                                                                                                                                                                                                                                                                                                                                                                   

Similar Messages

  • Check the validity of date

    hi..i'm creating a new user jsp page and in that i want to check whether the date entered by user as his/her date of birth is valid or not...i've taken three dropdown boxes to enter the date, month & year. how will i check the validity and concate three values and save it in database..thnx

    Validate it using java.util.Calendar which is set not to be lenient.
    Example: [http://balusc.blogspot.com/2007/09/calendarutil.html].
    Save it in DB using PreparedStatement#setDate().
    Example: [http://java.sun.com/docs/books/tutorial/jdbc/basics/prepared.html].
    The field in DB must be a DATE, DATETIME, or TIMESTAMP.

  • How to check the validation of RegEx

    Hi,
    My application needs users to enter RegEx. My question is how I can check the validation of the RegEx that users enter. The Class RegExp does not seem to provide any methods to check the validation of the RegEx.
    Regards,
    Haibin

    You would need to hand roll your own validator, unless someone knows of one that is out there. Flex does not validate RegEx.
    If this post answers your question or helps, please mark it as such.

  • How to check the validity period of saprouter ?

    Dear all,
    As per sap note 1178684, we can check the validity period of the saprouter by executing "sapgenpse get_my_name -n validity"
    I am wondering how to run that command in as/400 ?
    Please advise. I am not familiar with as/400 OS.
    Thanks
    Regards,
    Kent

    Hi Kent,
    please proceed as described on the http://www.easymarketplace.de/snc-iseries-setup.php
    logon with sidadm (or sidofr):
    (depending on the user, that is running the SAPRouter)
    CD DIR('/usr/sap/saprouter')
    ADDLIBLE LIB(SAPROUTER)    ??? or whereever the stuff is ...
    RMVENVVAR ENVVAR('SECUDIR')
    ADDENVVAR ENVVAR('SECUDIR') VALUE('/usr/sap/saprouter')
    RMVENVVAR ENVVAR('SNC_LIB')
    ADDENVVAR ENVVAR('SNC_LIB') VALUE('/usr/sap/saprouter/sapcrypto')
    CALL PGM(SAPGENPSE) PARM('get_my_name')
    Regards
    Volker Gueldenpfennig, consolut international ag
    http://www.consolut.net - http://www.4soi.de - http://www.easymarketplace.de

  • How to change the valid from date of the bom header?

    ECM is active in the system.
    I want to change the valid from date of the BOM header with the help of a change number.
    How can I change it?

    Hello
    Lets assume that, we are going to change Management for controlling Valid From date
    Steps to be followed for creation of Change No
    Tcode CC01 for Change No
    Click on Change Master
    Once you enter into Change master, maintain the description
    In the Valid from Date, maintain the date from which you BOM should be current
    Maintain the Status (01)
    Click on Ojbect Type, maintain for which Object types is the Change no needs to be active i.e. for BOM, Rtg, etc
    save the Change No
    After the change no is created
    Enter the Change No during the creation mode of BOM
    THe system copies the Valid from date from Change No

  • How to check the last receiveing date of a specific material

    Dear Experts,
    I want to check the last receiving date of an specific material.  Is there any standard t.code ?
    Mov.Type 101, 103.
    Thanks in advance.
    Dinesh

    Hi,
    Transaction code MB51 used to list out the posting date of GR received material document number, date and quantity.
    This report is basically used for list out all the material document based on sort out of posting date, movement type (101 ,103 etc).
    There you can easily find it the posting date of the GR receiving.
    MC.A is the Analysis report which is used for analysis of Material total Goods receiving and goods issues -basic list.
    - I suggest to use report MB51 - based on receiving movement 101, transfer 301,311 etc or issues movement 201 posting date.
    Thanks and Regards,
    Thiru

  • How to set the Valid-to-date (datub) of a BOM item

    Is there a way I can set the "Valid-to-date" of a BOM item?
    According to SAP documentation...
    Quote
    <i>"If you change a BOM using a change number, the system determines the valid-to date dynamically."</i>
    Unquote
    I want to "expire" a BOM item. Meaning I want to set the valid-to-date to a date in the past.
    Is this possible at all?
    Thanks for any input.
    Fred

    Ferry,
    Thanks for you reply.
    I do not see a field for the "Valid-to" date in the function module - CS_BOM_EXPL_MAT_V2. There is one for the "Valid-From" date called DATUV. But I would like to change the "Valid-from" date of the BOM item.
    Or is there another way to set the BOM item's valid-to date using this function module which I am missing?
    Fred

  • How to check the validation in UI before committing data?

    Hi,
    I'm using Jdev 11.1.2.1.0 version .
    I needed to check whether there is duplication of values in Boolean check box before committing the data into the Database.
    But this validation rule is to be checked based on the value selected in the Select One Choice drop down list in the page.
    I did it with adding a ValueChangeEvent in the drop down list and checking the values in the Boolean check box. It worked , but only in the case of earlier committed data in the database.
    How can i actually verify the data entered in the table in the page before it being committed into the DB ?
    Nigel.

    Hi,
    an improvement to your solution would be to move the major part of your code from the backing bean into a method on the ApplicationModuleImpl file (you create this from the AM editor)
      public boolean checkForDuplicate(){
           ViewObject vo = this.findViewObject("ResponseVO");
           int numRows;
           int j=0;
           numRows = vo.getRowCount();
           String rowValue = "a";
    //the part below of your code I don't like at all. Why do you need to increase a flag
    //and use an if statement ?
           for (int i=0; i<numRows; i++){
              rowValue = (String)vo.getCurrentRow().getAttribute("ResponseFlag");
              if(rowValue.equals("Y")){                           
                  j++;
                  if(j>1)
                      return true;
             return false;                           
        }This code you then expose on the AM as a client interface (same AM editor --> Java menu option)
    In the PageDef file (double click it to access the visual editor) click the plus icon next to the Bindings header. Choose "Generic Binding" --> method binding and point it to the AM and the exposed method. This creates a method binding "checkForDuplicate"
    Change your managed bean code to
      BindingContext bctx = BindingContext.getCurrent();
      BindingContainer bindings = bctx.getCurrentBindingsEntry();
      OperationBinding checkForDuplicate = (OperationBinding ) bindings.get("checkForDuplicate");
      checkForDuplicate.execute();
      boolean isDuplicate =  checkForDuplicate.getResult();            
      if(isDuplicate){
             FacesMessage msg = new FacesMessage(FacesMessage.SEVERITY_ERROR, null, "Two same respones!");
             FacesContext.getCurrentInstance().addMessage(null, msg);
                                               Frank

  • How to check the validity of recipient when sending email

    hi Gurus,
    i wanna send email thru class, and i need to know if the email is sent successfully, i can check the email status thru SOST.
    but is there any way to get a return message immediately as soon as  I 'm sending the mail  out.
    Thanks in advance.
    Desmond Yang

    S you are right.
    If you want to validate email id, use table ADR6. Check below code,
    "Get Ship-to-party email address
    DATA: l_f_adrnr TYPE adrnr,
          l_f_mail TYPE ad_smtpadr.
          SELECT SINGLE adrnr FROM vbpa INTO l_f_adrnr        " Get Address number
            WHERE vbeln = vbdkr-vbeln AND
                  parvw = 'WE'.  " 'WE' Ship-to-party
          IF sy-subrc = 0.
            SELECT SINGLE smtp_addr FROM adr6 INTO l_f_mail  " Get Email id from Address number
              WHERE addrnumber = l_f_adrnr.
          ENDIF.
          IF l_f_mail IS INITIAL.
            MESSAGE i503(sbcoms) WITH l_f_mail. " Throw a message saying Recipient is unknown
          ELSE.
            " Code to send mail
         ENDIF.

  • UIWebView - how to check the validity of url

    How can I check that a webView has started loading a webpage?
    I notice that the webViewDidStartLoad method is not called if there is some problem in the target url.
    Is there any way to notify the user that the url provided does not exist?

    How is the date entered? As a string? If so, use java.text.DateFormat to parse the string. If the string represents a valid date, a date object will be returned.

  • To check the License Expiry Date on EP??

    Hello All,
                   I have completed installing Permanent Licenses through VA in SAP EP.How to check the license expiry date in a stand alone server like EP??Moreover can u pls tell me what authentication is required for applying licenses through slicense??I did some with sap* & the others with ddic??

    How to check the license expiry date in a stand alone server like EP??
    You can see the license and all the details of it in the licensing adaptor using Visual Admin.
    Moreover can u pls tell me what authentication is required for applying licenses through slicense??I did some with sap* & the others with ddic??
    Any user with SAP_ALL will do.... doesn't matter if you install some with SAP* and some with DDIC
    Regards
    Juan

  • How do we decide the number of data base servers and application servers ?

    Dear Gurus,
    How do we decide the number of data base servers and application servers in BW ?
    How does this number help in data load balance and reporting needs ?
    Any hard n fast rule in the number of servers ?
    Regards
    Mohan

    Hi Mohan,
    Check the number of application server in the T-code SM66.... and also u can check the it in Sm50 on appplication server basiss./.
    From Sm37 u can see the application server Push button.. if u click on that also.. u can see the number of application servers in the system..
    Get into the individual application server and check how many Dialogue and background WP's are free,,
    If u see that the considerable number of WP are free(Waiting for task).. then u can shedule the loads..
    If most of the WP are  busy then u need to wait to trigger ur loads to maintain the load balancing..
    If one Application server is too busy then u can check the other Application Servers in the systems..
    And u can shedule the loads on a specific application sever level as well using the PC..
    Thanks
    I hope this is clear to u..
    Assign points if this helps

  • How to check the records in Master Data Table?

    Hi,
       I am trying to load the Master Data Table using the Flat File.Now how to check the records in Master Data Table?
    I done the following way:
    Info Provider->Info Object->Right Click->Display Data or Maintain Master Data
    But it's not showing the records.It's asking like CID from......To......
                                                                        CID(SID)from.............To.......
                                                                         here CID means customer id(characteristic).
    and showing some settings.
    Please guide me.
    Thanks & Regards

    Hi Sri,
    Go to T- code RSD1 and type your info object name and open the P- table in the infoobject then select execute symbol to see the updated  data in to master data info object.
    regards
    sap

  • I am planning to take unlocked  iphone5 which is from USA, let me to know how to check the phone is valid ?

    i am planning to take unlocked  iphone5 which is from USA, let me to know how to check the phone is valid ?.How can i check is that properly unlocked, stolen and service.

    IF you can actually yet purchase an unlocked iPhone4 8GB from the US Retail stores is not clear
    They are certainly available from Apple.com but only if you have a US credit card and a US delivery address
    I suspect you do not fit this requirement
    You also have to be careful as the Apple Retail stores sell no contract iPhones these are NOT unlocked
    However if you are able to purchase an unlocked iPhone4 8GB then it will certainly work with the Approved carriers in India

  • How to check the data of an archived table.

    I have archived a table created by me. I have executed the write program for the archiving object in SARA. Now how can check the data of my archived table.

    Hello Vinod,
    One thing to check in the customizing settings is your "Place File in Storage System" option.  If you have selected the option to Store before deleting, the archive file will not be available for selection within the delete job until the store job has completed successfully.
    As for where your archive file will be stored - there are a number of things to check.  The archive write job will place the archive file in whatever filesystem you have set up within the /nFILE transaction.  There is a logical file path (for example ARCHIVE_GLOBAL_PATH)where you "assign" the physical path (for example UNIX: /sapmnt/<SYSID>/archivefiles).  The logical path is associated with a logical file name (for example ARCHIVE_DATA_FILE_WITH_ARCHIVE_LINK).  This is the file name that is used within the customizing settings of the archive object.
    Then, the file will be stored using the content repository you defined within the customizing settings as well.  Depending on what you are using to store your files (IXOS, IBM Commonstore, SAP Content Server, that is where the file will be stored. 
    Hope this helps.
    Regards,
    Karin Tillotson

Maybe you are looking for

  • Schedule line date in Sale order for backward sched.

    Dear Experts, In my MTO Scenario, I want to Use Backward Scheduling, so as any change in Schedule line dates in Sale order shall take effect at least in planned order Stage, i.e in output of MRP, But not happening so.. I  have customized OPU5 and che

  • Wsimport, mapping of xs:date to java.util.Date via ext file, and -B option

    Summary: JDK 1.7.0_09 and wsimport and xjc that comes with it. Global JAXB binding to map xs:date to java.util.Date I have the following external bindings file: <?xml version="1.0" encoding="UTF-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSch

  • Finder unexpectedly quit while trying to restore its windows

    Hi. I was looking at my photos on a folder in my desktop. Suddenly my mac got slower and Finder popped out. It said "Finder unexpectedly quit while trying to restore its windows", and dont restore windows /  restore windows.       So I clicked restor

  • Process id 251 md import

    Although my iMac should be idling, the processor is reving up to over 70%. Culprit is a process called md import, process id is 251...it uses over 20 MB of real memory and 90 MB of virtual memory Parent process is launchd (1) How can I find out what

  • How can a get() return the POF bytes without deserializing?

    Is it possible to perform a get() from the cache without deserializing an object, anmd instead request the POF bytes directly? The use case is a middle tier server that is an extend client. It supports legacy downstream clients that should receive pa