webMethods

webMethods

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
  • 1.  Catch Try

    Posted Wed September 11, 2002 05:19 PM

    A while back someone published some code to extract the associate Error Message. Could you provide that information again? Thanks.


    #Universal-Messaging-Broker
    #Integration-Server-and-ESB
    #webMethods
    #broker


  • 2.  RE: Catch Try

    Posted Thu September 12, 2002 08:46 AM

    Hi, Tony:

    The following is what I posted at that time. I hope it is useful to you. As I remember some others had posted their codes.

    If you are using the wM Enterprise Integrator, the code
    below is from ERROR CATCH Block in the EI that we used to
    get the caught error text.

    try {
    ErrorCatchStepTry();
    }
    catch (AdapterException ErrorCatchStepEx) {
    declarationStep.stringExceptionMessage =
    ErrorCatchStepEx.getLocalizedMessage();
    declarationStep.$strExceptionMsg = true;
    ErrorCatchStepCatch();
    }

    declarationStep.stringExceptionMessage is a globle varible.
    So, you can use it everywhere within an EI component.

    The line:

    declarationStep.stringExceptionMessage =
    ErrorCatchStepEx.getLocalizedMessage();

    will catch error text. Then, you can print
    declarationStep.stringExceptionMessage using
    access.println()

    or you can assign the declarationStep.stringExceptionMessage
    to the error text field in Adapter::errorNotify and
    Adapter::error to publish and deliver.


    #Integration-Server-and-ESB
    #Universal-Messaging-Broker
    #broker
    #webMethods


  • 3.  RE: Catch Try

    Posted Thu October 10, 2002 03:30 PM

    HI,
    hi i want to subract a date also i create a new date object from the Broker date and i am using that in the select and update query there is now cimpiler error
    but the query is not executed.
    What is the correct way to do it.
    the code is
    out.swipe_date_1 = new BrokerDate( swipe_date.getJavaCalendar().get(Calendar.YEAR) ,swipe_date.getJavaCalendar().get(Calendar.MONTH)+1,swipe_date.getJavaCalendar().get(Calendar.DATE)-1 , 0 , 0 ,0 ,0 );


    #Integration-Server-and-ESB
    #broker
    #Universal-Messaging-Broker
    #webMethods


  • 4.  RE: Catch Try

    Posted Thu October 10, 2002 04:04 PM

    What error is being thrown, Kulandai? Is it a “ClassDefNotFound” Exception?


    #broker
    #webMethods
    #Universal-Messaging-Broker
    #Integration-Server-and-ESB


  • 5.  RE: Catch Try

    Posted Fri October 11, 2002 10:03 AM

    i shall exlain the whole process
    ther is Broker DAte
    and i get that date and derive all the
    year , month day
    and create a new BrokerDate
    of year,month and day-1
    in the format dd.MM.yyyy
    and pass that to the query
    which should find records
    in any of the dates
    but the query returns
    not values eventhough the table contains
    values of that condition

    what is that BrokerData
    and how does the getJavaCalendar and getJavaDate
    and toString methods behave

    Explain this ???

    Kulandai George


    #Universal-Messaging-Broker
    #Integration-Server-and-ESB
    #webMethods
    #broker


  • 6.  RE: Catch Try

    Posted Wed February 26, 2003 06:36 PM

    The declarationStep is the same that mapStep?
    I try but I don’t see the results…


    #webMethods
    #Integration-Server-and-ESB
    #Universal-Messaging-Broker
    #broker


  • 7.  RE: Catch Try

    Posted Thu February 27, 2003 02:51 PM

    Hi, Kundalai.

    I am pretty sure that I documented your exact issue a few months back. Read [url=“wmusers.com”]wmusers.com and tell me if that fits.

    Joe Jantz followed up the original post by saying that webMethods is aware of the issue.


    #broker
    #Universal-Messaging-Broker
    #webMethods
    #Integration-Server-and-ESB