Dynamic name physical file target
Hi
i have create logical file name with physical target name : /appli/interfaces/<FILENAME>_<SYSID>.csv
i want also add system time , date in this name.
anyone cab help me
thanks.
This is exactly the same as for <FILENAME> and <SYSID>. Those are all reserved words. In transaction file on field Physical file click F1 help and you will see a list of all reserverd words you can use and are subsituted automatically.
Here is part of the list:
Reserved word Word to be substituted
<OPSYS> Operating system in call
<INSTANCE> R/3 application instance
<SYSID> R/3 application name in SY-SYSID
<DBSYS> Database system in SY-DBSYS
<SAPRL> R/3 release in SY-SAPRL
<HOST> Host name in SY-HOST
<CLIENT> Client in SY-MANDT
<LANGUAGE> Log on language in SY-LANGU
<DATE> Date in SY-DATUM
<YEAR> Year in SY-DATUM, 4-character
<SYEAR> Year in SY-DATUM, 2-character
<MONTH> Month in SY-DATUM
<DAY> Day in SY-DATUM
<WEEKDAY> Day of the week in SY-FDAYW
<TIME> Time in SY-UZEIT
<STIME> Hour and minute in SY-UZEIT
<HOUR> Hour in SY-UZEIT
<MINUTE> Minute in SY-UZEIT
<SECOND> Seconds in SY-UZEIT
<PARAM_1> External parameter 1
<PARAM_2> External parameter 2
Similar Messages
-
Dynamically changing flat file target location in OWB10gr2.
Hi,
We have a requirement where in we are suppose to load a flat file from relational tables and the location of the flat file needs to be configurable at runtime.
Please suggest if this is achievable.
Regards,
PHD
Edited by: user1662077 on Jun 17, 2009 10:08 PMSee the post here for dynamically generating target file names using the OWB file operator as a target;
http://blogs.oracle.com/warehousebuilder/2007/07/dynamically_generating_target.html
Other techniques also include using a table function as a target.
Cheers
David -
Dynamic name for File through FTP Adapter
I am working on FTP Put and I have a requirement where in I have to generate the file with dynamic content in its name.I should actually embed a Purchase Order number in that file name follwed by a sequence number.I dont need any time stamp.Should I create a variable for this?
Help in this regard would be highly appreciated.Hi,
you have to enable the adapter specific parameter --> file name in both the sender and the receiver CC to get the input file name as output file name.
Refer this blog:
/people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14
Also you need to use this udf
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
String ourSourceFileName = conf.get(key);
return ourSourceFileName;
Also refer this blog:
/people/william.li/blog/2006/04/18/dynamic-configuration-of-some-communication-channel-parameters-using-message-mapping
Regards,
Nithiyanandam -
Dynamic name Flat file reading.
Hi all,
my client wants to schedule a BDC program for daily running.
But the file name is changed daily eventhough path is fixed.
can this be done.
can we read dynamic file from local system.
thanks in advance
Vikash.yes. so u can at initialissation for the paramter which takes the filepath name you can set to synamic filename as below
data : p_filename type RSVAR-FILEPATH.
initialization.
concatenate '/....SAP Forex Upload_' sy-datum+06(02) sy-datum+04(02) sy-datum+00(04) into p_filename. -
Dynamic Physical File names on AL11
Hi,
I have the following requirement.
I have almost 25 files to be exported onto AL11 using OpenHub from various infoproviders and I used the "Logical File name" option to do it.
I would like to have the physical file names as " ZINFOPROV_<DATE>_<TIME> " and Infoprovider tech. name should get populated dynamically somehow.
I was looking at the following thread for the same req : Re: Open Hub File name Change
I defined my logical file name definition as
Logical file Z_SALES
Name Used for SALES
Physical file ZINFOPROV_<DATE>_<TIME>
Data format ASC
Applicat.area BW
Logical path Z_SALES
I would like this ZINFOPROV populated dynamically.
Any have any inputs/suggestions.
Regards,
KumarHi Kumar,
You have a very good question and also shown the viewer of your post the way forward. Well i got your answer from your question only. Considering <DATE> as one kind of literals, you need a literal to identify the infoprovider as one part of your filename. Now my answer is not direct resolution but it may lead you to your answer. Here are the list of other literals that might be of use to you.....
Extract from the help.......
Physical path name
Platform-specific physical path under which files are stored. It most contain the reserved word <FILENAME> as a placeholder for the file name. IT can also contain further reserved words (see below).
Use
The physical path name is used by the function module FILE_GET_NAME at run time to create a complete platform-specific file name.
Procedure
Specify a path. You can include the following reserved words in pointed brackets. These are replaced with current values at runtime.
Reserved Word Replacement Text
<OPSYS> Operating system in call
<INSTANCE> R/3 application instance
<SYSID> R/3 application name in SY-SYSID
<DBSYS> Database system in SY-DBSYS
<SAPRL> R/3 release in SY-SAPRL
<HOST> Host name in SY-HOST
<CLIENT> Client in SY-MANDT
<LANGUAGE> Log on language in SY-LANGU
<DATE> Date in SY-DATUM
<YEAR> Year in SY-DATUM, 4-character
<SYEAR> Year in SY-DATUM, 2-character
<MONTH> Month in SY-DATUM
<DAY> Day in SY-DATUM
<WEEKDAY> Day of the week in SY-FDAYW
<TIME> Time in SY-UZEIT
<STIME> Hour and minute in SY-UZEIT
<HOUR> Hour in SY-UZEIT
<MINUTE> Minute in SY-UZEIT
<SECOND> Seconds in SY-UZEIT
<PARAM_1> External parameter 1
<PARAM_2> External parameter 2
<PARAM_3> External parameter 3
<P=name> Name of a profile parameter (see Report RSPARAM for valid values)
<V=name> Name of a variable (stored in variable table)
<F=name> Return value of a function module Naming convention for this function module: FILENAME_EXIT_name
<Y=name> Return value of a function module Naming convention for this function module: Y_FILENAME_EXIT_name
<Z=name> Return value of a function module Naming convention for this function module: Z_FILENAME_EXIT_name
Examples
Local directory for temporary files under Windows NT: D:\GLOBAL\ARCHIVE\<PARAM_1>\<FILENAME>
Local directory for temporary files under DOS:C:\TMP\<FILENAME>
Local directory for temporary files under UNIX: /usr/<SYSID>/local/tmp/<CLIENT>/<FILENAME>
Dependencies
The function module for the run-time variable <F=name> must meet the following requirements:
Name
The name must begin with "FILENAME_EXIT_".
Parameter
An export parameter with the name "OUTPUT" must exist. No structure may exist for this parameters.
Import parameters are only supported if they have default values.
Table parameters are not supported.
Valid example: FILENAME_EXIT_EXAMPLE.
I hope this leads you to your resolution.
Regards
Raj
Edited by: Rajesh J Salecha on Oct 9, 2009 1:48 PM - Not able to make it properly formatted...
Edited by: Rajesh J Salecha on Oct 9, 2009 1:54 PM -
Xml file in dynamic file name in file receiver adapter
Hi,
I'm doing the dynamic file name in file receiver adapter. I have done as per instructed in /people/jayakrishnan.nair/blog/2005/06/20/dynamic-file-name-using-xi-30-sp12-part--i
All turned out okay. I have got the file name I require. Except that the file format is XML and I need to suppress the filename node occupied by the dynamic file name.
The content conversion mentioned in /people/sravya.talanki2/blog/2005/08/11/solution-to-the-problem-encountered-using-variable-substitution-with-xi-sp12, does not seem to solve my problem. As it is only for file format other than the XML one, because we only do the content conversion if we want to "convert" the format of the content from XML to the other format.
Does anybody have the solution to my problem? thanks in advanceThank you Raj for the direction
The way to do it is :
1. In ID, advanced tab, put a check on the adapter-specific message attributes - file name.
2. Put a "*" on the file name scheme
3. In IR, create a UDF to set up target file name :
DynamicConfiguration conf = (DynamicConfiguration) container
.getTransformationParameters()
.get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
// set up file name for receiver adapter
String SourceFileName = conf.get(key);
conf.put(key, TargetFileName);
return " ";
4. Map the above UDF to the header level of the target structure.
Regards,
Idi -
Regarding file name in the target system
Hi..
I have got a file name releated problem in XI.
I have configured a flow in XI system using proxy and after mapping process creates a output file in target machine as a "Test<Date-Time Satmp>.dat".
Test is the file name and adding date-time stamp to that.
I am using file adapter.
Now my requiremnt is that instead of "<b>Test<Date-Time Satmp>.dat</b>", I need to create a file as
<b>"<Date-Time Satmp>Test.dat</b>" .
Please let me know if anyone has come across similar situation.It is urgent.
I know there is an option to create dynamic file names in file adapter but i think it isn't enought to solve my problem.Hi jahangir laskar,
For the Receiver communication channel, (file adapter)
Enter in the fields
1. Under <b>File Access Parameters</b> section,
<i>File Name Scheme : test.dat</i>
2. Under <b>Processing Parameters</b>
<i>File Construction Mode : Add Time Stamp</i>
This should work, i just tested it out.
Srinu. -
Mapping physical file name to logical file name
Hi All,
Can anybody let me know wht is the procedure to map a logical file name to physical file name. wht is the use of logical file name when there exists physical file name?
Thanx in AdvanceAs far as creating the Logical path its done through the transaction code file by using options
Steps are:
1. Logical file path definition which is logical file path name.
2. Assignment of physical path to logical path - where we give the physical path to the logical path name defined in the last step.
After creating the Logical path the procedure to attach the file name to the Logical path is as follows:
Use the function Module C13Z_FRONT_END_TO_APPL to upload the file from the front end to the application server.
Source file on front end will be the CSV file path which is to be uploaded to the application server
Target file on application server will be the physical path of the file on the application server where the file is to be uploaded.
Attach the physical path of the file on the application server to the Logical file using transaction code file.
Logical File: The Logical name of the file which will be used by the interfaces to upload the file
Physical file: The name of the physical file on the application server
Logical path: The path of the physical file on the application server where it is stored.
The possible reason for the use of Logical file name could be we can have directories within SAP in which we can have logical files stored. These files can be used by various interfaces. Different Logical paths can be used for different interfaces. the second reson can be to give more user friendly name to the file rather than a long physical name to the file. -
Assign Logical file name for the physical file path through Program
Hi all,
I am having a physical file which is getting generated dynamically. It is having the date and time stamp in its name which is added at runtime.
Now I need to assign a logical file name for the physical file path through the program.
Is there any FM or any other method to assign the same.
GauravI think it is not possible. becuase the date & time added at runtime. so if you check the table PATH you can find filename and their definitions
a® -
Retrieving dynamic name files from FTP
Hello,
I have a scenario where PI needs to pull a file from a FTP site with a dynamic format of VendorYYYYMMDD.txt; A new one is placed there every day.
One posting has an example is from ASM to PI to FTP: Re: Change in time stamp format in receiver file name. However mine is FTP to PI to ECC. I have thought of using a synchronous call from Sender ABAP proxy to PI to Receiver FTP adapter; However, the FTP adapter cannot poll (i.e. it only has target name).
Question: What is the best method to put a dynamic name into the Sender FTP adapter?
Regards,
John_Xi>>Question: What is the best method to put a dynamic name into the Sender FTP adapter?
I think you can do in the file sender adapter " Run operating system command before processing" where you can specify shell script which willl create the file name dynamically you want or rename the placed file using the script as per the requirement. For further help .. check this link
http://help.sap.com/saphelp_nw04/helpdata/en/e3/94007075cae04f930cc4c034e411e1/content.htm -
Recive a file with dynamic name
Hi All,
I want to receive a file with dynamic name containing date stamp to it.... eg File_20080123.txt , File_20080122.txt etc.
Can anybody suggest how to do it?
Thanks,
AtulAtul,
Are u using mapping program in ur interface? If yes you can go ahead with ASMA + Dynamic Configurations for renaming the file.
Have u tried this option?
See the below Solution
Check the ASMA File for both sender/receiver channels.
Write the below code UDF in mapping program
//Get Input date. Don't pass anything to this UDF except the Date.
//Map the output to the root node of the target.
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
String fname = conf.get(key);
String ret = fname"_"Date
return "";
raj.
Edited by: Raj on Jan 23, 2008 4:09 PM -
Information about file Id, Logical file name and Physical file name
Hi All,
I am testing one program. Selection screen has 3 parameters, File Id, Logical File Name and Physical file name. In Physical File name, i am giving complete file name with path. But it is giving error. Please tell me, what is File id and what all information i need to enter for logical file name and physical file name.
Thanks
Puneet Aggarwalhi,
try using this for filename.
parameters : p_file like rlgrap-filename.
Thanks,
Gaurav -
Changing of the physical file name of the file after archiving
Hi all,
We are in process of archiving and completed the process successfully and archived to o:\PRODSID\<filename>.
When refresh is happening from Prod to Quality the archived data will come as O:\PRODSID\<filename> and the archived files will not be accessible since quality system is not able to find the path with O:\PRODSID\<filename>.
Is there anyway i can change the physical file name of the archived files to correct path O:\QUALITYSID\<filename>, i need to change only the SID only from PRD to QUALITY.
Thanks,
Subhash.GHi Subash,
Do you want change the Physical File name or the Path from PROD to SID.
Path :- in the transaction called FILE, double click on Logical Path Definition , select the Logical File and double click on "Assignment on Physical Path to Logical Path" and you can change FILENAME also here
Thanks,
Sravanthi -
Logical file names and Physical file names
Hi Guys...
Can you let me know what is the difference between Logical file names and Physical file names?
Regards,
RohitUsing Logical Files in ABAP Programs http://help.sap.com/saphelp_nw04/helpdata/en/9f/db95e635c111d1829f0000e829fbfe/content.htm
Creating and Defining Logical Filenames
http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb3df8358411d1829f0000e829fbfe/content.htm -
Dynamic File name in File Adapter
Hi,
I have a requirement to pass dynamic file name in File Adapter.
Is there any way to pass a variable for the file name attribut in file adapter.
I am looking for some options apart from %yyMMddHHmmss%,%SEQ%...etc
Please suggest if any of you have information on how to put values from a variable to file name attribute in file adapter
regards
SaijuHi Saiju,
Yes there is.
Assign your file name to a variable, let's say 'fileName'.
Now go to your invoke activity(for the specific fileadapter) -> Property tab-> find a property call jca.file.FileName -> in the value field assign 'fileName' variable.
That's it... (assuming you are using 11g)
Arik
Edited by: Arik on Jun 27, 2012 3:12 PM
Maybe you are looking for
-
How can I record my voice on iMovie without needing to place a photo or video in?
I'm trying to make an anime review. But before placing photos in it, I wanted to record my voice first before adding pictures in it. So I was wondering what do I do to actually get my voice in it without it being cut because there were no photos or v
-
Spry horizontal menu - submenu items are displaying laterally instead of vertically in IE
I am currently building a website in Dreamweaver CS5 (on a mac) that includes a horizontal Spry menubar. The drop down items appear vertically, as I want them to in Firefox, Safari, and Chrome, but not in Internet Explorer for Windows. Instead, the
-
On my iMAC with Mountain Lion, I exported a Video from iPhoto to the desktop, put it into a burn folder, and burned it to a DVD. When I open the Video on the the DVD, it loads as DSCN0097.AIV. When I click on the play button, I can see the progress l
-
Macbook Air 13 shuts down if power cord isn't connect
My new (apr 2012) mb air 13 has randomly started shutting down if the power cord is not connected...At first, it was just randomly shutting down every 5-10mins, rebooting, and then shutting down again. I updated the software, and now - when plug into
-
Adobe Form configuration error
Dear All, I have configured my adobe forms on an abap+java stack. once i try running a program on tcode: SFP, on execution it gives the following error: System Error FPRUNX Message no: 001 Could you please help me sort this problem. Thanks!