cancel
Showing results for 
Search instead for 
Did you mean: 

file naming convention

Former Member
0 Kudos

Setup dynamically , file naming convention sequence to be incremented for every 1 hour

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

U can follow the below mentioned steps.

File Construction Mode : Add Counter

Counter Definition:

Prefix: _

Format: 0

Step : specify from where u need the counter to start from

Mode: Immediately.

This works with Transport Protocol "File System (NFS)

Edited by: pragya dubey on Aug 7, 2008 9:14 AM

Former Member
0 Kudos

Hello Dubey,

Thank you for your reply...I would like to add time stamp and date into it ..Can I do that automatically for evert message here

santhosh_kumarv
Active Contributor
0 Kudos

Use the option Add Time stamp in the File Constructuion mode. Remember you can either add a counter or timestamp but not both using the standard functionality.

Thanks

SaNv...

Former Member
0 Kudos

>>file naming convention sequence to be incremented for every 1 hour

Could you re phrase this sentence.

As far as naming conventions of file, it can be achievable from the Consruction Mode in the File receiver adapter. But if you need more then then you can also go for DynamiConfiguration in Mapping and override thefile name based on your requirements

thanks

farooq.

Former Member
0 Kudos

Hello,

>>DynamiConfiguration in Mapping and override thefile name based on your requirements

Could you suggest me how to do this...

Former Member
0 Kudos

Refer this Blog: https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/2664

Refer this link: http://help.sap.com/saphelp_nw04/helpdata/en/43/03612cdecc6e76e10000000a422035/frameset.htm

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

DynamicConfigurationKey key = DynamicConfigurationKey.create(
    u201Chttp://sap.com/xi/XI/System/Fileu201D,
    u201CFileNameu201D);

String valueOld = conf.get(key);
if (valueOld != null) {
    String valueNew = valueOld.replaceAll(u201Cinputu201D,u201Doutputu201D);
    conf.put(key, valueNew);
}

For complex file name you can create UDF and paas the Input that you need in the naming convention.

Thanks

Farooq.

Edited by: Farooq Farooqui on Aug 7, 2008 12:46 PM

santhosh_kumarv
Active Contributor
0 Kudos

In the receiver file adapter select the File Construction Mode as Add Counter.

Thanks

SaNv...