Skip to Content
avatar image
Former Member

dynamic attribute file name

Hi All,

I am trying to use dynamic attribute file name using UDF in message mapping:

<i>String filename = null;

filename = "Yahoo";

DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);

DynamicConfigurationKey key1 = DynamicConfigurationKey.create("http://seeburger.com/xi/common" , "dtSubject");

conf.put(key1,filename);

return "";</i>

But its just giving me the name on the receiver side as in the sender side.

I have checked FileName in Dynamic attributes in the reciever adapter.

Regards,

XIer

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Sep 23, 2007 at 09:40 AM

    Modify your code

    DynamicConfigurationKey key1 = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");

    Add comment
    10|10000 characters needed characters exceeded

    • Varun,

      I think he is using Seeburger as receiver adapter, thats y he specifically gave all the parameters. The config which u gave is for File adapter..

      XIer - Did u solved it? Sorry I never worked in Seeburger adapter, no idea 😔

      raj.

  • avatar image
    Former Member
    Sep 24, 2007 at 04:21 AM

    your return statement looks like <i>return "";</i>

    Return the filename that you have assigned inside the UDF and can be achieved by

    conf.put(key1,filename);

    <b>return filename;</b>

    Do refer this blog as well

    /people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14

    Add comment
    10|10000 characters needed characters exceeded