IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
Expand all | Collapse all

ConvertToString throwing Nullpointer exception

  • 1.  ConvertToString throwing Nullpointer exception

    Posted Thu August 21, 2003 07:42 PM

    Hi,
    i am doing mapping from delimited flatfile to 835 EDI mapping in 6.0.1.
    i am done with segment mapping , and when i do converttoString service i am getting NullPointer exception.
    i am passing the EDI document as input and ns record as actual EDI document.
    what could be the problem here?
    when i look into the EDI document from my mapping , only i see ST01 as 835 and ST02, SE01 and SE02 all are blanks.
    any help is appreciated.its some what urgent.

    Thanks,
    Rao.


    #webMethods
    #Integration-Server-and-ESB
    #edi


  • 2.  RE: ConvertToString throwing Nullpointer exception

    Posted Thu August 21, 2003 08:03 PM

    Make sure your mapping of segments are perfect(IData Values).

    And Instead of giving nsRecord,try with passing the ffschema param(EDIFFSchema.X12.V4010:T835)of convertToString,This should work.

    If this problem still exists,then problem might be with mapping itself.

    (Above mentioned schema will be stored in EDIforTN Package.)

    HTH.


    #edi
    #webMethods
    #Integration-Server-and-ESB


  • 3.  RE: ConvertToString throwing Nullpointer exception

    Posted Thu August 21, 2003 09:56 PM

    Hello RMG,
    i tried this by passing ffschema param.but i am getting this error now
    “com.wm.ff.parse.StorageException: [FFP.0015.0005] Specified an invalid schema WmEDIforTN.X12.V4010:T835, is not a Flat File Schema.”

    Thanks,
    Rao


    #webMethods
    #Integration-Server-and-ESB
    #edi


  • 4.  RE: ConvertToString throwing Nullpointer exception

    Posted Thu August 21, 2003 10:10 PM

    Hello RMG,
    Sorry about this. i did wrong refernece .it’s " EDIFFSchema.X12.V4010:T835". not WmEDIforTN.
    its working now.but why it is not working for nsRecord.

    Thanks for your help.
    Rao.


    #edi
    #Integration-Server-and-ESB
    #webMethods


  • 5.  RE: ConvertToString throwing Nullpointer exception

    Posted Thu August 21, 2003 10:11 PM

    Pls check,Is that 835 schema exists in EDIforTN package.
    This schema will be automatically generated when you install EDI document Types in TN Console.

    Pls make sure schema exists and loaded properly.


    #Integration-Server-and-ESB
    #edi
    #webMethods


  • 6.  RE: ConvertToString throwing Nullpointer exception

    Posted Thu August 21, 2003 10:14 PM

    Oh it was fast,good to know its working.

    I haven’t tried with ns record,anyway functionality should be the same.


    #edi
    #Integration-Server-and-ESB
    #webMethods


  • 7.  RE: ConvertToString throwing Nullpointer exception

    Posted Fri August 22, 2003 03:51 PM

    Hell RMG,
    ConvertToString is modifying the format of some fields. ex. field1 value is 3489.07 in EDI values document, but the service convertToString is formating this as 3.489E7 or something like that. how to overcome this formating.Can you please let me know soon.

    Thanks,
    Subba.


    #edi
    #webMethods
    #Integration-Server-and-ESB


  • 8.  RE: ConvertToString throwing Nullpointer exception

    Posted Fri August 22, 2003 04:01 PM

    Check in the 835 schema about the field which you are referring this behaviour.some times its all depends on schema picklist constraint or invalid content may be passing to it.

    If its not clicked,may be someone will chim on this.


    #webMethods
    #Integration-Server-and-ESB
    #edi


  • 9.  RE: ConvertToString throwing Nullpointer exception

    Posted Fri August 22, 2003 04:33 PM

    What is the data type of “field1”? I believe the only way a translation like that would occur is if the field is typed as a float or double, thus a toString() call will return exponential notation format.


    #webMethods
    #Integration-Server-and-ESB
    #edi


  • 10.  RE: ConvertToString throwing Nullpointer exception

    Posted Sat August 23, 2003 04:18 PM

    As in EDI documentation explained, i modified the Flow.xml in /integrationServer/packages/WmEDI/config/ . i modified the autoformat = ‘false’ in formatdecimal format service.
    and reload the package.it is working now.

    Thanks for all your help.

    Rao.


    #edi
    #webMethods
    #Integration-Server-and-ESB


  • 11.  RE: ConvertToString throwing Nullpointer exception

    Posted Fri May 20, 2005 12:51 AM

    I had this same problem and recommended that the config/format.xml file be changed for our development work. However, there is a lot of stuff with EDI already in production on IS 6.1 using EDI. None of it uses the convertToString flow. My question is what other flows in the WmEDI package use the formatDecimal FormatService ?
    Other than regression testing all the EDI stuff in production, how can we make sure this change does not cause another problem?


    #Integration-Server-and-ESB
    #webMethods
    #edi


  • 12.  RE: ConvertToString throwing Nullpointer exception

    Posted Fri May 20, 2005 08:15 PM

    Well, I looked thru the wmEDI package and the WmFlatFile package. When I look for dependents of wm.b2b.edi.util.formatServices:formatDecimal there are none. Probably because the code to wm.b2b.edi:convertToString
    is hidden or the code that runs the “find dependents” service won’t find the relationship inside a java service.
    Anyway, the convertToString and convertToValues are the only services that use the FormatInfo document - which interacts with formatDecimal.
    Srini, are you reading this? Does anybody think I’m way off on this?


    #edi
    #Integration-Server-and-ESB
    #webMethods