IBM Sterling Transformation Extender

Sterling Transformation Extender

Come for answers, stay for best practices. All we're missing is you.


#Sterling
#Supplychain
 View Only
  • 1.  table look up

    Posted 04/07/04 09:33 AM

    Originally posted by: SystemAdmin


    I have 2 input...one is xml file another one file containing some values
    NOW as I read xml file I need get value from another input file corresponding to the xml value ..All I want is to take xml value and go against the tabel(file) and get corresponding value from the table file).

    When I do that what happening is that it is writing as many Number of records from The file Did u come across any such things..? Do u have any magic to resolve this..?
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender
    #DataExchange


  • 2.  Re: table look up

    Posted 04/08/04 01:50 AM

    Originally posted by: SystemAdmin


    If you post your rule we may get a better idea of what is happening.
    Jan
    #IBM-Websphere-Transformation-Extender
    #DataExchange
    #IBMSterlingTransformationExtender


  • 3.  Re: table look up

    Posted 04/08/04 05:39 AM

    Originally posted by: SystemAdmin


    Let me clear again..i am using functional Map
    value in A xml file should match value in B FILE ...when it happens i need another value in B file same record and put that in o/p..
    ..ex:

    xml file: 2

    file: 2,a
    3,b
    4,c
    so need the o/p as ..2,a
    #IBM-Websphere-Transformation-Extender
    #DataExchange
    #IBMSterlingTransformationExtender


  • 4.  Re: table look up

    Posted 04/08/04 06:42 AM

    Originally posted by: SystemAdmin


    So you need to use LOOKUP.
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender
    #DataExchange


  • 5.  Re: table look up

    Posted 04/08/04 07:21 AM

    Originally posted by: SystemAdmin


    when i do that..i am getting output accurance is same as records in 2 File..
    i am using teh functional map which has simple rule.
    Lookup(file2b,fil2a=file1a)..

    not sure why it is reading and writing when it looks up
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender
    #DataExchange


  • 6.  Re: table look up

    Posted 04/08/04 07:45 AM

    Originally posted by: SystemAdmin


    The use of lookup is as below
    In your case it woulkd be lookup(file b,field in file a = field in file b

    The LOOKUP function sequentially searches a series, returning the first member of the series that meets a specified condition.

    Syntax

    LOOKUP (series-object-expression, single-condition-expression)

    Meaning

    LOOKUP (series_to_search, condition_to_evaluate)

    Returns

    This function returns a single-object.
    Returns the first member of series_to_search for which condition_to_evaluate evaluates to TRUE. Returns NONE, if no member of series_to_search meets the condition specified by condition_to_evaluate.

    Examples

    LOOKUP ( Account#:Customer , Company Name:Customer = "ACME" )

    This example returns the Account# of Customer whose Company Name is ACME.

    LOOKUP ( Part#:Row:DBSelect , Model#:Row:DBSelect = ModelCode:Legacy & Serial#:Row:DBSelect > "123")

    This example returns the Part# of DBSelect where the Model# in that row matches the ModelCode of Legacy and the Serial# is greater than "123".

    Copyright @ 2002 by Mercator Software, Inc.
    In your case the condition is field in file a = field in file b
    #DataExchange
    #IBMSterlingTransformationExtender
    #IBM-Websphere-Transformation-Extender


  • 7.  Re: table look up

    Posted 04/09/04 07:51 AM

    Originally posted by: SystemAdmin


    Difficult to assess an issue like this through this forum. You may want to put together a test case with the data/trees/map and send to support.

    Prior to doing that:

    Look at the output element the rule is on - does it have a range greater than 1? If it does and you only want to build a single element you may need to "index" the output element.

    Look at the input elements in your output rule - are any of them defined as a repeating series or a group on the input? Are any of them a nested element of a group that repeats? You may have selected the wrong input element into the rule. XML can be especially tricky in this regard.
    #IBMSterlingTransformationExtender
    #IBM-Websphere-Transformation-Extender
    #DataExchange


  • 8.  Re: table look up

    Posted 04/29/04 05:07 AM

    Originally posted by: SystemAdmin


    i final go tteh results. had this rule in main map and called teh functional map to using look up function and also removed ellips function form the rule
    Thanks for evryoen who helped me
    #IBMSterlingTransformationExtender
    #DataExchange
    #IBM-Websphere-Transformation-Extender