How to validate incoming messages with mandatory field coming as null/empty

Hi,
I want to validate the incoming messages received by the file adpater.
1. Need to check that all the mandatory fields(minoccurs=1) has values, else it should return fault. But what happening now is even though the mandatory fields are empty/null, file is being read by the file adapter and not getting faulted.
2. I have tried using the Validate Activity/Assign Activity but this is a business fault and not sytem fault, hence no faults are auto generated.
3. We are presently using the if/switch activity and putting the conditions manually in order to validate the mandatory fields and hence it is throwing the business faults explicitly.
4. But if there is 200 fields mandatory out of 500 fields schema, then we need to hardocde manually all 200 fields. Please advise me if this is possible in any dynamic way.
Thanks
Edited by: 902781 on 15.mar.2012 07:33

Dear vijay,
This is my xsd::
<?xml version="1.0" encoding="UTF-8" ?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="http://www.example.org"
targetNamespace="http://www.example.org"
elementFormDefault="qualified">
<xsd:element name="exampleElement">
<xsd:annotation>
<xsd:documentation>
A sample element
</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:sequence>
*<xsd:element name="element1" type="xsd:string" minOccurs="0"*
nillable="false"/>
*<xsd:element name="element2" type="xsd:int" minOccurs="0"*
nillable="false"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
I tried the above xsd as well as
<?xml version="1.0" encoding="UTF-8" ?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="http://www.example.org"
targetNamespace="http://www.example.org"
elementFormDefault="qualified">
<xsd:element name="exampleElement">
<xsd:annotation>
<xsd:documentation>
A sample element
</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:sequence>
*<xsd:element name="element1" type="xsd:string" minOccurs="1"*
nillable="false"/>
*<xsd:element name="element2" type="xsd:int" minOccurs="1"*
nillable="false"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
But instance is getting completed even though the mandatory string field(element 1) is empty/null like:
<element1></element1>
What I feel is, string will accept all the values whether it is int, date, long and in the same way it is accepting null character.
Please let me know if you have any solutions to overcome this.
Thanks again.

Similar Messages

  • How to put Sales employee (Splcode) Mandatory Field, when adding A/R invoice

    Hi,
    Kindly solve, How to put Sales employee (Splcode) Mandatory Field, when adding A/R invoice.
    Regards,
    Rajeev.

    Follow this step..
    1. In SQL Server, go to the SAP B1 Database you're using. 
    2. then on the Object Explorer , go to Database Folder, explode the SAP DB->Programmability->Stored Procedures->SBO_SP_TransactionNotification * the only Stored Procedure that is allowed to be edited. Just right click and modify
    3.  Try to paste this -> and click F5
    If
    @object_type ='13' and @transaction_type in ('A','U')
    Begin
    If EXISTS
    select DocEntry from ONIV
    Where DocEntry = @list_of_cols_val_tab_del
    and  SlpCode<>'-1'
    Begin
    set @error_message = 'Please select the Sales Employee'
    set @error = 1
    END
    END
    Regards
    Kennedy

  • How to validate xml file with XSD schema ??  in JDK1.4.2

    How to validate xml file with XSD schema ?? in JDK1.4.2
    i dont want to use new Xerec Jar ...
    Suggest option ...

    Please do not double-post. http://forum.java.sun.com/thread.jspa?threadID=5134447&tstart=0
    Then use Stax (Woodstock) or Saxon.
    - Saish

  • How to create pdf files with text field data

    how to create pdf files with text field data

    That looks like it should work, but it doesn't.
    I opened the PDF I had created from Word in Acrobat (X Pro). Went to File > Properties. Selected "Change Settings". I then enabled "Restrict editing...", set a password, set "Printing Allowed" to "none", "Changes Allowed" to "none", and ensured that "Enable copying of text..." was disabled.
    I saved the PDF file, closed Acrobat, opened the PDF in Reader, and I was still able to select text and graphical objects.
    I reopened the PDF in Acrobat, and the document summart still shows everything as allowed. When I click on "show details" (from File > Properties) it shows the correct settings.
    Any ideas?

  • How to export xy graph with indicator field.

    hi,
     I want export my graph in .emf format.For this i have used invoke node>>Image export. If i use this , i can only export the graph not other indicator filed(numeric and string indicatror).how can i export graph with indicator field??
    here is .vi that i have used.
    Solved!
    Go to Solution.
    Attachments:
    Unbenannt 2.vi ‏12 KB

    Thanks for your post in our Discussion Forum,
    is it necessary to export the picture in the .emf Format?
    Otherwise I can provide two possibilities:
    The easiest way to make a screenshot of a certain area of the frontpanel is to 
    create a SubVI with all the elements you want to take a screenshot from and
    then take a screenshot from the whole frontpanel of the SubVI.
    This works fine although the frontpanel is not visible while the picture is taken.
    The screenshot can be taken with a method-node as seen in the example attached to this post.
    Another possibility is to crop a screenshot of a whole frontpanel to the region which you are interested in.
    How this works is described here: http://forums.ni.com/t5/LabVIEW/take-screenshot-of-part-of-front-panel/td-p/1613750
    The downside is that you have to manually set the region which might change due to scrolling or changes on the panel.
    Best regards,
    Peter
    Attachments:
    VI Screenshot.vi ‏13 KB

  • How do I process messages with status = "Holding"

    Hi,
    How do I process messages with status = "Holding" from the RWB-Message Monitoring - Adapter Engine?
    I did a quick scan for records with errors in the same queue (ConversationID), but could not find any.
    I tried to cancel the one with the smallest sequential number, but I got the error - "Unable to cancel 1 of 1 messages; update the status"
    Please help.
    Thanks
    Sudheer

    Hi,
      "Holding comes into play when ur scenario is having multiple inbound interfaces and you checked "Maintained order at runtime"in interface determination in ID. Suppose  message will hit first inbound interface once it is successful then it will hit second inbound interface. If first inbound interface fails then most of the message will be in "Holding" status depends upon XI AF queues ID.
    I did a quick scan for records with errors in the same queue (ConversationID), but could not find any.
    You will not find bcoz of AE archiving settings.
    Try to check the with business guys, whether they need the order of processing. If not the case try to Uncheck the box "Maintain Order at runtime".
    Regards,
    Rao.Mallikarjuna

  • How to concatenate single quote with any field like 'VBAK'

    Hi,
    How to concatenate single quote with any fields.
    say for example I have table name as MARA, I have to pass that table name to other fields with single quote , like I have to pass that as
    tab name = 'MARA'.
    but how to do this,
    below statement will not work
    concatenate '''  'MARA'   ''' into string.. it's giving syntax error...
    Regards,
    Mrunal

    gv_name = 'MARA'.
    gc_quote = '''.
    CONCATENATE gc_quote gv_name gc_quote INTO value.
    Pushpraj

  • How to skip a selection screen mandatory field in debugging mode with out changing the code?

    Hi Team,
    In my report there is two fields on selection screen, one is obligatory field , but i just want to execute the report(for testing per pus) with out entering  the data for the mandatory field with out changing the code. could u let me know which event and how to debug the report. or else  in debugging mode how can i change that field as non mandatory field.
    Regards,
    Venkat.

    If the value is not of importance how come it became obligatory in your program?
    Any how you can do one thing...Put some value in your obligatory field, put a debugger point where you are interested in  and use the pencil tool to change the value of the field while debugging. 
    Regards,
    Philip.

  • How to add a message to a field in a dataTable row?

    I have a dataTable with a var "selectedUser". Each row has a 2 fields: username & password, both editable and 2 buttons: save and delete. In the "UsersControllerBean.updateUser" method associated with the update button, I want to be able to add an error message to the field on the corresponding row where the button has been clicked. How can I retrieve the client Id of the field from the "selectedUser" var associated with the dataTable (that I get from the RequestMap) to add the message to it?
    Is there an easier way of doing this? (no, thanks no link button!)
    Thanks
    Fred
                   <h:form id="users">
                   <h:dataTable border="1" width="100%" value="#{UsersControllerBean.usersList}" var="selectedUser">
                        <h:column>
                             <f:facet name="header">
                                       <h:outputText value="Id"/>
                             </f:facet>
                             <h:outputText value="#{selectedUser.userId}"/>
                        </h:column>
                        <h:column>
                             <f:facet name="header">
                                       <h:outputText value="Name"/>
                             </f:facet>
                             <h:inputText id="username" required="true" value="#{selectedUser.username}"/>
                             <h:message for="username" style="color: red"/>
                        </h:column>
                        <h:column>
                             <f:facet name="header">
                                       <h:outputText value="Password"/>
                             </f:facet>
                             <h:inputText id="password" value="#{selectedUser.password}"/>
                             <h:message for="password" style="color: red"/>
                        </h:column>
                        <h:column>
                             <f:facet name="header">
                                       <h:outputText value="Actions"/>
                             </f:facet>
                             <h:commandButton value="Save" action="#{UsersControllerBean.updateUser}"/>
                             <f:verbatim>��</f:verbatim>
                             <h:commandButton value="Delete" action="#{UsersControllerBean.deleteUser}" immediate="true"/>
                        </h:column>
                   </h:dataTable>
                   </h:form>

    Dear Friends,
    Finally, I got the answer.
    I required to add the messages to error log for invoice. Error log is displayed in Tree format.
    The error log getting displayed while processing invoice with help of table VBSK.
    We can update the VBSK table information with required message to put in log.
    Best regards,
    Amol Chaudhari.

  • How to Post XML Messages with SOAP Headers to a Trading Partner URL

    Hi All,
    Greeting to the Oracle B2B Community. We are currently working on how to post a Custom XML Message with SOAP Headers to a Trading Partner URL. I would really appreciate if anybody could provide me some inputs or links to some documentation on how to achieve the above requirement. The details are below:
    1. Our Internal Application generates a Flat File (PO Extract).
    2. The Extract then needs to be transformed to an XML Message. We are planning to use BPEL to do the transformation to XML Message.
    3. Once it is transformed to an XML message it needs to be posted to the Trading Partner URL as an HTTP Post and with SOAP Headers.
    We are planning to use B2B to do the posting but I am not sure on how to do the set-ups and what all parameter files in B2B needs to be updated in order to achieve the same. Also it is mandatory that we send SOAP Headers in the XML Message.
    Thanks In Advance for your help.
    Regards,
    Dibya

    Hello Dibya,
    As you are already doing the transformation from Flat file to XML in BPEL which is typically the capability of B2B, please use the Soap binding in BPEL to send the document to Trading partner.
    Rgds,Ramesh

  • Default Back Button ( F3 ) with mandatory fields ( module pool program )

    Guys,
    I'm editing another persons dialog program and as mentioned in the subject line, there are mandatory fields. WIthout them being filled, I cannot use the back button to exit the program as it prompts me to first fill the mandatory fields.
    How can I get past this?
    I did a /h for debug mode and pressed Back but it did not even show the debugger.
    Regards,
    Kevin

    <b>Use AT exit-command.</b>
    MODULE mod [ AT {EXIT-COMMAND|CURSOR-SELECTION} ]
               [ ON {CHAIN-INPUT|CHAIN-REQUEST} ]
               [ SWITCH switch ].
    Extras:
    1. ... AT EXIT-COMMAND
    Effect
    The statement MODULE of the dynpro flow logic calls the dialog module mod of the ABAP program. You can use MODULE either as a keyword or as an addition of statement FIELD. When using it as an addition, the call of the dialog module depends on conditions for the screen fields.
    As a keyword, the statement calls the dialog module mod of the respective ABAP program. At the event PAI, you can use the additions AT and ON to specify conditions for the call of the dialog module.
    At the event PBO, you can call any dialog module defined in the ABAP program with the addition OUTPUT. At the events PAI, POH and POV, you can call any dialog module defined with the addition INPUT or without any addition. If the dialog module mod does not exist in the ABAP program, an untreatable exception is triggered. After processing a dialog module in the ABAP program, processing of the dynpro flow logic is resumed after the position of the call, unless the screen processing is completed within the dialog module.
    You can use MODULE as a keyword only at the events PBO and PAI. At the events POH and POV, you can use MODULE only as an addition to the FIELD statement.
    Note
    Do not mix up the MODULE statement of the dynpro flow logic with the identically called statement MODULE for defining dialog modules in the ABAP program.
    Addition 1
    ... AT EXIT-COMMAND
    Effect
    Addition AT EXIT-COMMAND at the event PAI causes module mod to be called exactly if:
    The function used to trigger event PAI has function type "E"
    Into the input field of the standard toolbar, the user entered a character string starting with "E" and confirmed it using ENTER.
    The dialog module is called before the automatic input checks defined in the system or in the ABAP Dictionary and independent of its position in the event block. The only screen field transported to the ABAP program is the OK field. If the function that triggered the PAI event does not fulfill any of the above prerequisites, the MODULE statement is not executed.
    If several MODULE statements have the AT EXIT COMMAND addition, only the first one is executed. If no MODULE statement has the addition AT EXIT COMMAND, a normal PAI processing is executed: The predefined input checks are executed and then the PAI event block is processed sequentially. Provided the screen processing is not terminated in the dialog module mod, after the return from the dialog module, the complete PAI processing is executed. You must not use the addition AT EXIT COMMAND in connection with the statement FIELD.
    Note
    The function type of a function is determined in the Screen Painter or Menu Painter. Usually those functions of the user interface are defined with function type "E" that are assigned to the icons Back, Exit and Cancel in the standard toolbar of the GUI status. Therefore, the called dialog module should terminate the screen processing and allow security checks, if required.

  • How to convert internal table with dynamic fields to XML

    Dear all,
    I met a problem like the following:
    The aim is to transform the following parameter to XML
    IT_FIELD stores the dynamic filed name of the internal table,with these fields, the dynamic internal can be created by cl_abap_tabledescr=>create(it_field)
    IT_VALUE stores the value of the internal table dynamically created with dynamic fields.
    For example
    IT_FIELD =>
    line1: FIELD1
    line2: FIELD2
    line3: FIELD3,
    three lines in this internal table.
    dynamically created internal table structure FIELD1 FIELD2 FIELD3
    And IT_VALUE=>
    1          2          3   (First line)
    11        22        33
    two lines of data.
    Do you have any idea about how to transform the IT_VALUE to XML here? And also the transformed XML to the IT_VALUE.( we may need remember IT_FIELD here for later XML to IT_VALUE.)
    Hope I describe the problem clearly.
    Any inputs will be appreciated.
    Edited by: Max Tang on Jan 12, 2009 3:46 PM
    Edited by: Max Tang on Jan 12, 2009 4:14 PM

    Hi,
    you need to implement a bit of coding for that.
    With the 'do varying' statement abap provides a loop over those fields. Within this loop you can build up a new internal table with one entry for each period and amount.
    kind regards
    Siggi
    PS: I am not very familiar with CO, but I guess there will be a standard extractor for that.

  • How to send a message with javamail api

    Hi, anybody can tell me how i do to send a message with javamail?
    Thanks.
    Daniele.

    [rossifumi80],
    Here's a simple JavaMail application SendMessage.java that will connect a SMTP host and send a mail message out:
    import java.util.Properties;
    import javax.mail.*;
    import javax.mail.internet.*;
    public class SendMessage {
      public static void main (String args[]) throws Exception {
        String host = args[0];
        String from = args[1];
        String to = args[2];
        // Get system properties
        Properties props = System.getProperties();
        // Setup mail server
        props.put("mail.smtp.host", host);
        // Get session
        Session session = Session.getDefaultInstance(props, null);
        // Define message
        MimeMessage message = new MimeMessage(session);
        // Set the from address
        message.setFrom(new InternetAddress(from));
        // Set the to address
        message.addRecipient(Message.RecipientType.TO,
          new InternetAddress(to));
        // Set the subject
        message.setSubject("Hello JavaMail");
        // Set the content
        message.setText("Welcome to JavaMail");
        // Send message
        Transport.send(message);
    }HTH.
    Allen Lai
    Developer Technical Support
    SUN Microsystems
    http://www.sun.com/developers/support/

  • How to send a message with a photo to a company?

    I AM S DISABLED SENIOR WITH SHORT-TERM MEMORY. PLEASE TELL ME HOW TO SEND A MESSAGE AND INCLUDE A PHOTO I HAVE ON MY i-PHONE 5S?
    THANK YOU IN ADVANCE FOR THE ASSISTANCE.
    FLIGHTLEADER-1

    Open the photo, assuming it is in Photos, and then in the lower left corner under the photo is a box with an up-pointing arrow.  Tap that box, and then the photo will have a blue circle with a checkmark in its lower right corner and the word Next at the upper right.  Tap Next, then choose how you want to send the photo, by text message, email, and so on.  Simply address the method you have chosen and put in any text you want to include.

  • How to send SOAP message with attachment?

    Hi Experts,
    How do I simulate to send a SOAP message with an attachment? Can I use XMLSpy?
    Please help.
    Thanks,
    Shobhit

    Ravi,
    With the generic SOAP client, it asks for the http based wsdl file location. But my wsdl has been generated by XI and I have the file stored on my desktop.
    Something to do with the path http://zpidd01:8030/XISOAPAdapter/MessageServlet?channel=NetworkPartners:NP_Order_BS:NP_SOAP_Sender_CC ??
    Stefan,
    my scenario is to send a SOAP request with attachment and post the attachment in ECC through the ABAP server proxy.
    WebService Client -
    SOAP----> XI -
    ABAP PROXY CALL ---> ECC
    Need further assistance from both of you how to achieve this scenario.
    Thanks,
    Shobhit
    Edited by: Shobhit Swarup Mathur on Jul 24, 2008 4:34 AM

Maybe you are looking for

  • How can I remove pictures from my IPad

    How can I remove photos from my IPad

  • IDS signature tuning... interval questions.

    Just starting out trying to tune some signatures to fit our environment, and looking for clarification on some parameters of IDS signatures. For example: 2152 - ICMP flood It uses the "Flood Host" engine with the action parameters: Limit type: percen

  • Sub-contracting at two different vendors directly monitored by the company.

    Initially the raw material is supplied to a sub-contracting vendor A by the company to process it. After vendor A finishes processing it, the material will be shipped by vendor A to vendor B on behalf of the company for further processing which marks

  • Itunes wont install on to my windows vista 32 bit PC

    I have just purchased a ipod touch 32gb and am trying to download itunes to get started. But i am unable to download itunes its goes through the set-up, downloads quick time player and gets to the end and says theres a problem and something has inter

  • Custom Dimension

    Dear All At present I am using Business Area in ECC 6.0 (EHP4).  The requirement is to derive Financial Statements at a Branch/Plant level.  I was told that Business Area functionality is out of use and there wont be any further enhancements in the f