Dynamic folder creation

Hi,
Without making any repository changes, is it possible to create folder based on dates and put the files in the corresponding date folder of that day?
Folder name : 05/26/2010  - Files created on 05/26 should be placed automatically into this folder
Folder name : 05/27/2010  - Files created on 05/27 should be placed automatically into this folder
Thanks

Check the Adapter Specifi Message Apttributes in the Receiver File Adapter and check the Directory option under it .
You will have to include a UDF to in the message mapping to set this Attribute for just one time and then never touch it .
the udf code will look like this
  DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey key = DynamicConfigurationKey.create("http:" + "/" + "/" + "sap.com/xi/XI/System/File", "Directory");
conf.put(key, dir);
dir is the variable that goes as input to the UDF and it shoudl be set on current date which ever way you want .
this udf can be included in the root node of the output and it just needs to get executed everytime the mapping runs.
Check the  create target directory if it does not exist option int he receiver comm channel .
This  will create the folder on its own based on the current date and you will not have to touch the message mapping or configuration  ever.
ThankYou.

Similar Messages

  • Dynamic folder creation on server

    hi all,
    i'm working with 9i and using webutil for file tranfer from client to server now i want this uploaded file to be stored in a folder created dynamically on the server..any help

    create the procedure in your form. below is my sample codes:
    PROCEDURE chkstatus_mkdir_4ws( wk_ip_adr in varchar2,
    usr_name in varchar2,
    pss_wrd in varchar2,
    accnt_ok out boolean) IS
    ftp_dir_file UTL_FILE.FILE_TYPE;
    ftp_log_file UTL_FILE.FILE_TYPE;
    ftp_dir_file_name varchar2(40);
    ftp_log_file_name varchar2(40);
    ftp_command varchar2(60);
    veh varchar2(6) := LOWER(NAME_IN('GLOBAL.VEHICLE_LINE'));
    phs varchar2(25) := LOWER(NAME_IN('GLOBAL.DESIGN_PHASE'));
    tid varchar2(20) := LOWER(NAME_IN('GLOBAL.TNUMBER'));
    Oracle_dir varchar2(6);
    v_ErrorCode number(8); ---PROBLEM HERE
    v_ErrorText varchar2(200);
    v_str1 varchar2(500);
    Begin
    --- build the ftp directive file
    Oracle_dir := '/tmp';
    ftp_dir_file_name := usr_name || '_ftpcm_dir';
    ftp_log_file_name := usr_name || '_ftpcm_log';
    ftp_dir_file := UTL_FILE.FOPEN(Oracle_dir, ftp_dir_file_name, 'W');
    UTL_FILE.PUTF(ftp_dir_file, 'open %s\n', wk_ip_adr);
    UTL_FILE.PUTF(ftp_dir_file, 'user %s %s\n',usr_name,pss_wrd);
    UTL_FILE.PUTF( ftp_dir_file, 'cd hlink.projects\n');
    UTL_FILE.PUTF( ftp_dir_file, 'mkdir e3d\n');
    UTL_FILE.PUTF( ftp_dir_file, 'cd e3d\n' );
    UTL_FILE.PUTF( ftp_dir_file, 'mkdir %s\n', veh );
    UTL_FILE.PUTF( ftp_dir_file, 'cd %s\n', veh );
    UTL_FILE.PUTF( ftp_dir_file, 'mkdir %s\n', phs );
    UTL_FILE.PUTF( ftp_dir_file, 'cd %s\n', phs );
    UTL_FILE.PUTF( ftp_dir_file, 'quit\n' );
    UTL_FILE.FCLOSE(ftp_dir_file);
    --- invoke the ftp command to run the directive file----
    ftp_command := 'ftp -n -v < '
    || Oracle_dir || '/' || ftp_dir_file_name
    || ' > '
    || Oracle_dir || '/' || ftp_log_file_name;
    host(ftp_command);
    --- Read results from ftp log file to determine if supplied account worked ok
    ftp_log_file := UTL_FILE.FOPEN(Oracle_dir,ftp_log_file_name, 'R');
    accnt_ok := FALSE;
    LOOP
    BEGIN
    UTL_FILE.GET_LINE(ftp_log_file,v_str1);
    EXCEPTION
    WHEN NO_DATA_FOUND THEN
    message('The workstation selected is not reachable from DTDB application.');
    message(' ');
    EXIT;
    END;
    IF INSTR(v_str1,'230') > 0 THEN
    accnt_ok := TRUE;
    EXIT;
    ELSIF INSTR(v_str1, '530') > 0 THEN
    message('The incorrect User Name or Password was supplied.');
    message(' ');
    EXIT;
    End IF;
    END LOOP;
    UTL_FILE.FCLOSE(ftp_log_file);
    --- Exception handeling
    Exception
    When UTL_FILE.INVALID_OPERATION THEN
    UTL_FILE.FCLOSE(ftp_dir_file);
    Message('INVALID OPERATION... ftp 2 workstation');
    WHEN UTL_FILE.WRITE_ERROR THEN
    UTL_FILE.FCLOSE(ftp_dir_file);
    Message('WRITE ERROR.... ftp 2 workstation');
    WHEN UTL_FILE.INVALID_PATH THEN
    UTL_FILE.FCLOSE(ftp_dir_file);
    Message('WRONG PATH... ftp 2 workstation');
    WHEN UTL_FILE.INVALID_MODE THEN
    UTL_FILE.FCLOSE(ftp_dir_file);
    Message('WRONG MODE... ftp 2 workstation');
    WHEN UTL_FILE.INVALID_FILEHANDLE THEN
    UTL_FILE.FCLOSE(ftp_dir_file);
    Message('Invalid file handle "ftp_dir_file" ftp 2 workstation ');
    WHEN OTHERS THEN
    UTL_FILE.FCLOSE(ftp_dir_file);
    v_ErrorCode := SQLCODE;
    v_ErrorText := substr(SQLERRM, 1, 200);
    message('Just known Internal Error: '||v_ErrorCode||'=>'||v_ErrorText);
    End;

  • Dynamic folder creation possible?

    Hi all-- I'm new to the scripting thing and have been trying to learn but am getting nowhere. Wondering if anyone could help me.
    My current workflow is:
    Batch including all subfolders using an action that crops, levels, and adds a border then saves the image as tiff to a folder called tiff, resize and save as jpg to another folder called jpg.
    It's a pain sorting through the tiff and jpg folders to separate out the images into new folders named as per the originals.
    Is there any way to have a script look at the folder you are currently batching from and create and save to folders in each of the tiff and jpg folders named as per the original folder being batched from?
    I would appreciate any help or advice you may be able to give.
    Janice

    Janice-83 wrote:
    Hi again,
    This creates properly named subfolders containing jpeg and tiff copies of each image, which is good, but the jpeg images have not gone through the action 1 step and are therefore not cropped. I know I could set up action 2 to include another crop step, but that seems redundant. There must be a chunk of code I could use to do this elegantly. I even tried taking apart the Dr. Brown script with no luck.
    It might seem redundant but is not. As I wrote after a version is save the Images Processor Pro reverts the image back to the original file open state.  So it back to its original state not resized and without any alteration preformed by any action as you have observed.  The Image Process Pro allows you to process your Original Image as many ways as you need to. Nothing accumulates. If your processing files not open documents the files are opened once and remain unaltered and the save versions are independent and have no effect or any other version. This is elegant what your trying to do would be ugly IMO have version accumulate effect would prevent you from creating independent versions and a version may have done some destruction to a point you can not create the version you want to create.
    I wrote you could use a single action for the way you wrote about your work flow you stated "My current workflow is: Batch including all subfolders using an ""action that crops, levels, and adds a border then saves the image as tiff to a folder called tiff, resize and save as jpg to another folder called jpg."" "  With that action both the Tiff and Jpeg versions would have the border. Now you have changed your story. Your Tiff does not have a border only the jpeg version does. Your output is more complex  you need two actions. Action 1 crops and levels.  Action 2 crops, levels, and adds a border.  The Image Processor Pro gives you versions where everything is independent simple straight forward easy no interference...   Now you can accumulaye things if you wish.  You could have action 1 and have an action 2 that plays action 1 and then add a border.  Version Tiff is still independant from version Jpeg.  You just include one action in a second action and accumuate you steps that way..
    I have not looked at The Image Processor or Image Processor Pro code.  I don't feel I need to either. It would be very easy to revert the image back to the original  open state. All the script needs to do is dupe the current document and create the version from the dupe after the version is saved then all the script needs to do is to close the dupe it created the version from without save. Dupe and create next version  all versions created  close image and move on to the next image. Simple elegant.
    The script does all the hard work for you. Batch, handles output location. Has a self modifying dialog the lets tailor the number of output file types you want to create. You can tailor all file type save options, optionally resize and control output file naming.  Its action running options enable you to put your own spin on versions. The script even has plug-in code support so it can be recorded it use in actions and bypass it dialog when the action is played. It is a very complex script well beyond elegant. All you need to do is create some simple actions to tailor versions of your images. While your computer grinds away your free to have a life.

  • Dynamic Table Creation & Fill Up

    Hello,
    Can anyone please guide where I can find examples for dynamic table creation (programmaticaly), with dynamic number of columns and rows, used to place inside text components (or whatever) to fill them with data.
    All programmatic.
    Using JSF, ADF BC
    JDeveloper 10.1.3.1
    Thanks
    Message was edited by:
    RJundi

    Hi,
    Meybe this article helps: http://technology.amis.nl/blog/?p=2306
    Kuba

  • Dms connector no dynamic folder

    Hi
    I'm trying to setup the dms connector. I'm stuck in the typical 'no dynamic folder' problem. As I've read on sap documentation and in the forums, I've installed the plugin 2003 or later. I've also configured the 'variant prefix' as 'KM' at the portal dmsrm repository and have created some 'KM_XXX' selection variants at cv04n. Unfortunately, the only thing I see in the 'Document Explorer' is the dms EDIPUBLICROOTFOLDER folder
    These are the software versions:
    1. DMS connector v1.0
    2. PI v2004_1_470 SP SAPKIPZI5C level 12
    3. PI_BASIS v2005_1_620 level 0 no SP
    4. R/3 v4.7
    5. Netweaver 2004s stack 9, portal v7
    any clues?
    Thank you very much
    Alberto
    PS: There's another post with the same title but it's not a question. Please post your comments in this thread. Thank you

    hi Alberto...
    Would be grateful if you can share some documents on the DMS front...We are planning to integrate the portal with DMS ...
    One basic question are the documents stored within the DMS already indexed and portal will just point to it ....or we need to index them seperately....
    any help from you on this would be great...
    cheers
    Aj

  • Does Seeburger's SFTP adapter support dynamic filename creation

    Hi all,
    Does the SFTP adapter support dynamic filename creation.
    If yes, then do we have to use UDF's and are there any specific settings that have to be done in the SFTP communication channel.
    Please provide a blog which helps in the configuration process of the above case.
    thanks,
    younus

    Dynamic Creation of File using counter in Seeburger Variable:
    1. Configuration Needed in the Communication Channel:
    The process of dynamic creation of files can be done we have to select the following checkbox in the receiver channel:
    Dynamic Attribute in receiver Channel:
    Import the following modules:
    Localejbs/Seeburger/solution/sftp
    Localejbs/Seeburger/AttribMapper
    Localejbs/ModuleProcessorExitBean
    Enter  the desired file naming convention:
    Use the Parameter GetCounter("ID") to the place where the counter is expected to come.
    2. Configuration Needed in the SeeBurger Workbench:
    If the J2EE server is listening on a port different from 50000 (which is the standard for the SAP client 000), the port number must be configured:
    Login into the seeburger workbench using the URL
    http://<localhost>:<port number>/seeburger/index.html
    Select Property Store.
    Create or edit the following property:
    Parameter
    Value
    Namespace
    http://seeburger.com/xi/SeeFunctions
    Key
    provider.servlet.server
    Value
    http://localhost:50000/ (where the port number 50000 must be set
    accordingly to the J2EE server configuration).
    Note: The configured value (server URL) has to end with a slash (/). Otherwise,
    SeeFunctions will not work correctly.
    If we need to start the counter from any specific value , it can be configured in the SeeBurger workbench, this value can be maintained in Mapping Variables :

  • Deployment question - dynamic folder of unknown files during install

    Hi,
    I'm curious to see if this would be possible in flex.  It doesn't seem to be directly possible, so perhaps there's a workaround?
    The question:
    Can I have a folder of files next to an .exe (or .air) install that will place this folder into the install location?
    The background:
    I'm making a photo viewer app.  I want it to be able to work completely offline, in case they don't have an internet connection.  I want this to be able to be used both in Windows and Mac.  I figured an adobe air program would be a good way to do this.
    The photos are going to be dynamic.  I want to burn a cd with the .exe and a folder of images that are not available at the time of packaging.  Can I do this?  Do I have to make some kind of custom install exe to copy the files over after installing the program?
    I was thinking of a workaround.  I'd rather see if I could do the above- but this would be an alternative.  Let the program install normally.  When the program starts up it checks for a CD in the drive and copies the files to the program files before loading.  If the program can't find any images in the program file and the CD ROM is not in the computer, I would throw an error saying to put the CD in the drive.  This would work right?  I see the storagevolumeinfo class but it doesn't seem like there's a way to differentiate types of removable media; only that they are removable.  Am I wrong?

    I see file type of "CDFS" on my CD-ROM drive.  I'm assuming I can use this to make sure the removable drive is a CD based on googling it.  It sounds like my backup plan can work.  I'm still curious about the main question with the dynamic folder on install though.

  • Does UCM support dynamic page creation on contributor mode.?

    Hi All,
    Does UCM support dynamic page creation on contributor mode.
    We want to create new pages and link it into the existing pages
    is that possible?
    Thanks
    ~Hari

    You can create new secondary pages in contributor mode - you would normally do this via a dynamic list fragment though technically you could also achieve it by switching region content and creating new data files. You can then use the linz wizard to link between pages.
    If you are talking about creating new primary pages and sections in your site then you would need to use something like Site Studio Manager fragment.
    Tim

  • Automating Folder Creation

    Here's what I want to do. I'm trying to automate client folder creation. I have a directory called clients. Every time I create a new folder in the clients folder, I'd like for it to automatically ask me what I'd like to name the folder, then I would like it to create 6 directories inside the created folder titled "legal" "spec files" "correspondence" "modules""graphic design" and "archived materials".
    How would I go about that with automator?

    A couple of options. The first uses automator and a shell script, but you would run the workflow which asks for a folder name instead of you creating it first, as you requested. The second uses Folder Actions so that when you create a new folder in your clients folder it will ask for a name and create the folders.
    Automator Method:
    1) From Files and Folders, drag over a "New Folder" action.
    2) Enter a default name for the folder in the Name: field (or leave blank)
    3) Select your Clients folder in the Where: field
    4) Click the "Options" button and tell it to "show this action when the workflow runs"
    5) From the Utilities, drag over a "Do shell script" action
    6) Select the /bin/bash shell
    7) in the Pass input field select "As arguments"
    8) Enter this code mkdir -p $1/legal/ $1/spec files/ $1/correspondence/ $1/modules/ $1/graphic design/ $1/archived materials/
    Save this workflow and run it when you want to create the new folder. If you have quick keys, launch bar, Quicksilver, or the like, you could set up a shortcut...or, you can use cmd-space to call up spotlight and search for you workflow name and launch it from spotlight.
    For the Applescript option:
    I had some glitches with it in that it seemed to re-run the script after I changed the name. I couldn't figure out if the name change drove the script to run again. Also, after creating the new folder, you have to wait a few seconds for it to trigger. Kind of annoying, I thought.
    First, copy this script to a new Script Editor script (Applescript folder).
    property dialog_timeout : 30 -- set the amount of time before dialogs auto-answer.
    on adding folder items to this_folder after receiving added_items
    try
    tell application "Finder"
    set theFolder to item 1 of added_items
    set response to display dialog "Please enter a folder name:" default answer "New Client"
    if button returned of response is not "Cancel" then
    set the name of folder theFolder to (text returned of response)
    make new folder at folder theFolder with properties {name:"legal"}
    make new folder at folder theFolder with properties {name:"spec files"}
    make new folder at folder theFolder with properties {name:"correspondence"}
    make new folder at folder theFolder with properties {name:"modules"}
    make new folder at folder theFolder with properties {name:"graphic design"}
    make new folder at folder theFolder with properties {name:"archived materials"}
    end if
    end tell
    on error theErr
    display dialog theErr
    end try
    end adding folder items to
    Save it as a script in your user/Library/Scripts/Folder Action Scripts/ folder. Run the Folder Actions Setup script in the Applescript folder and attach this script to your "Clients" folder:
    1) Click on the Enable Actions checkbox
    2) Click the "+" button in the left pane and find your clients folder
    3) Click the "+" button in the right pane and find your script you just saved.

  • Folder creation in UCM

    Hi All,
    There is on security group eg:-New Profile,if any new profile check-in ucm automatically the folder structure will create on that perticular profile.
    The folder structure should be ---root folder EMPID_EMPNAME(Emp001_ABC)
    Inside root folder 5 sub-folders like -----Emp Resume,Education details, Experience Details,Salary,Administrator
    Let me know is there any possibility to create automatic folder creation when the new profile check-in inside UCM.
    Give me your valuable suggestions on this issue.
    Thanks.

    hi,
    Actually through mine custom page of mine component in which suppose there is two text box like
    Parent folder
    Child folder
    when i submit the name a new folder should be created under contribution folder with child folder name.
    Scenario is that suppose a project comes and on mine custom page when i enter the project name a folder with same name should be created under contribution folder by calling new folder creation service.
    Plz if u can help me out.
    Thanks once again...

  • Robocopy not copying the folder creation date

    We migrate the data between 2  Windowsfile servers using robocopy and it works finew ith issues. Only issue is it doesnt copy the folder creatiopn date from source to destination server, it does copy the file creation date without any issues. Command
    we use is as below.
    robocopy.exe %1 %2 /COPYALL /MIR /ZB /R:10 /W:2 /TEE /DCOPY /LOG+:robocopy_%3.log
    This command is called using a batch file where we specify the source and destination using the below syntax.
    call Robocopy_Module.bat "C:\Backup" "C:\Restore"
    Kindly advise if this is normal behaviour , if not what is the correct command used to copy the Folder creation dates.

    I was using like this
    Go to CMD prompt,
    RUN as Administrator
    Type  
    robocopy "source path" "destination Path" / MIR
    It will copy including time stamps.
    or create seprate folder in a destination place and copy everything into that folder.
    It will work.

  • Custom property not displaying at folder creation or Details screen

    Hello everyone
    I have created a custom boolean property that I need to have displayed both at folder creation and in the Details screen of a folder after it's created.  The property is in the default namespace, and is in the Custom group.  I have created a properties file for the label and created the necessary meta data extension.  The folder validity pattern is " / " and the Resource Type listed is "normalct" so that it's active for folders only.
    Then I went to Property Groups and listed my new property in the Group Items field of the Custom group.  The Custom group is a part of "all_groups" so that group is displayed both when a new folder is created in KM and when the Details screen of a folder is displayed.
    <i>However,</i> my custom property isn't displaying under the Custom tab when I go to create a new KM folder, nor when I view the Details screen of an existing folder.  What configuration am I missing?  Do I have to develop a custom property renderer for each new property I need to create?  I was hoping I could achieve this result with configuration changes only, but I must be missing something.
    Any help would be greatly appreciated and rewarded. 
    Thanks in advance,
    Fallon

    Hi Fallon,
    actualy, if you want this property to be displayed only for folders and not for documents, you don't need to specify the resource type for folders. Setting "/" or "/**" for "Folder Validity Patterns" and "" (empty) for "Document Validity Patterns" should be enough.
    If you sill experience problems, you have to check all settings, for example with the settings suggested in this <a href="https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/2654">weblog</a>. If you use the "default" Property Group in the property settings, you don't have to enter the <b>Property ID</b> in a special Property Structure Group that in turn is integrated in the all_groups Property Structure Group.
    Hope this helps,
    Robert

  • Home Folder Creation w/Active Directory

    If this has been asked a million times, just point me to the url for the answer...
    I have done the leg work and have the "magic triangle" working - I can login and auth to AD and get my preferences from OD. I want our user's home folders to reside on our Windows server. I have shared out \\server\students on the Windows server and in AD I am pointing their home folder to our Windows server, but I can't get the permissions right. When I point a new user's home folder in AD to our Windows server, it creates the folder \\server\students\jtest.
    When the user logs in, none of the subfolders are created. Can someone give me some pointers on how permissions need to be set so the subfolders are created on first login?
    This is all pretty new and I'm happy that I got the triangle to work - if I can get this all important piece, I'll be set.
    Thx in advance!

    Hi
    A lot of this depends on how many OUs you have; how deep they go; and how many directories you have nested in each OU or the particular OU the directory for home folder creation is within. The accepted 'recommendation' is not more than 3 deep - generally. Having said that I have made it work with OUs 7-10 deep. Gets trickier after that.
    In my experience the non-creation of expected directories is generally down to permissions not being assigned properly - as you've guessed. Essentially users must be given read/write access all the way down the nested directories. I have seen permissions assigned correctly to a parent folder, with a set of different permissions applied to the next folder down and the next one along again with the correct permissions applied. Folder creation fails when permissions are set in this way.
    What is interesting is the log-in does not fail though you are greeted with the usual "the home folder exists on an SMB or AFP Server etc" dialog box when getting to the desktop. You sometimes get this at the log-in window as well. Although you can also see the message for other reasons - usually down to poor DNS configuration.
    You should be able to log in as the local admin and look at the system.log in Console. You should see an error starting with 'NSurl etc etc. . . ' listed. If you do that's an indication it's a permissions problem.
    Beyond this and without being there it's difficult to tell?
    Hope this helps, Tony

  • Using iOS Folder Creation Function on OSX Desktop Dock?

    Just a thought, but I'd love to keep my clutter on the dock on my macbook low by using the folder-creation function on my iPhone and iPad. Anyone else know of a way to do this or think it's a good idea?

    Information about my computer is as follows:
    Machine Name:          iMac G5
    Machine Model:          PowerMac8,2
    CPU Type:          PowerPC G5  (3.1)
    Number Of CPUs:          1
    CPU Speed:          2 GHz
    L2 Cache (per CPU):          512 KB
    Memory:          1 GB
    Bus Speed:          667 MHz
    Boot ROM Version:          5.2.5f1
    It looks like this at the back:

  • Need New for Read Access except Folder Creation

    Hi,
       I have some problem which is as follows:
    I have created the folder <b>ABC</b> in KM Content -> documents -> ABC and given the Read Rights to the user <b>user1</b>, then created the KM Navigation iView.
    Now user1 can see the ABC folder and the documents under it. The problem is that now I want to have New in the context menu and in New except folder creation, all are needed.
    How I can achieve it, please help me on this.
    Regards,
    Deep

    Hi,
    From previlages perspective If user1 should create folders under ABC, then he need more than just READ rights!!
    If you need a context menu New Folder, then you should set <b>new_folder</b>
    UICommand to your KM Navigation iView's Layoutset's Collection Renderer. The Collection Renderer property is <b>Collection  Command Group  </b>
    So have a new UI Command group and add the <b>new_folder</b> UICommand to it.
    http://help.sap.com/saphelp_nw70/helpdata/en/87/3d48475ee8bd448c4031aa98d90524/frameset.htm
    Greetings,
    Praveen Gudapati
    [Points are welcome for helpful answers]

Maybe you are looking for