CcBPM Correlation based on filename

I am new to ccBPM.  The problem I am trying to solve is we have 2 files written; 1 in XML with an element containing the name of the 2nd file and a 2nd file that is a PDF document.  We can get to these files via the File Adapter (NFS).  But we must put the files to another site via the File Adapter using FTP; they must arrive at this site, PDF, the XML.  Simple...
My thought was to set up a ccBPM Process but I am not clear if I am headed in the right direction.
Any suggestions?
Many thanks,
Rich

Couple of ways you can implement your requirement
1) using CCBPM.  You are right ... You can implement Collection Pattern using correlation based on the field name that has pdf file .
Refer SDN for this. You can also refer SAP BASIS software component in ESR where you get this pattern and implementation
2) Without Using CCBPM:  This is an another way you create simple file to file for XML.  In the mapping area, You can write java FTP logic to move the pdf file from source directory to target directory.  There are plenty of free java ftp api are available. You can  use that too.
Hope that helps

Similar Messages

  • FTP Transfer: based on filename it needs to be moved to different directory

    Hi,
    I am doing a FTP transfer of file from one location to another. In this scenario, based on filename the file needs to be moved to Directory A or Directory B.
    Is this possible having a single receiver file adapter?
    Regards,
    Ashish

    Hi Ashish
    What you can do is
    1. You can pick the file from location and use variable substitution to deliver the file on base of filename. But the limitation is folder name should have some characters common to filename as well.
    2. You can write file to a temperory location and then execute OS command to move the files to appropriate folders
    3. Create two communication channels and enhanced receiver determination to find our which folder based on filename at runtime.
    Thanks
    Gaurav

  • Why is Spotlight not finding images based on filename?

    I have 25,000 photos that I have meticulously named, but when I try to do a Spotlight search based on filename, nothing shows up.  For example, if I type "Disney," then about 200 photos with "Disney" in the file name should appear, but they don't. I can find the images on my own, for example "091012 CA Disney Family Vacation2," but Spotlight can not. Why?

    Hi there tau_ataina,
    Based you the issue you are describing, you may need to re-index Spotlight. Take a look at the article below for more information. 
    Spotlight: How to re-index folders or volumes
    -Griff W. 

  • How to automate layer stack creation including layer masks based on filename?

    Hi
    Can someone help me to create a script that would automate the creation of layers including a layermask, based on filenames.
    E.g.
    Unwrap_001_diffuse.jpg
    Unwrap_001_mask.jpg
    Unwrap_002_diffuse.jpg
    Unwrap_002_mask.jpg
    The image with the suffix "_diffuse" would be the layer and the image with the suffix "_mask" would be the layermask.
    In the above example the script would create 1 psd with 2 layers.
    If there is no file with the ending "_mask", the script would only create a single layer with no layermask.
    Any help would be highly appreciated.
    Thank you
    Boris
    I

    For starters the Folder-selection dialog could be used if the images are all in one Folder.
    var theFolder = Folder.selectDialog ("select folder");
    And then the method getFiles could be used to get the files.
    var theFiles1 = theFolder.getFiles("*_diffuse.jpg");
    Loading the file as Layers can be done with the ScriptingListener code for File > Place for example and finding the corresponding mask files seems fairly easy.
    Are they grayscale or RGB?
    But why jpg anyway?
    Are those renderings?
    If so why not tiffs or some other non destructively compressed file format?

  • TOC based on filenames rather than heading names.

    I created a WebHelp project by linking to a FrameMaker 12 book. After first generating the output, the TOC and index were not included although they were part of the book. I click an icon in the TOC pod to generate the TOC, but the TOC is now based on filenames rather than heading names. How can I fix this?

    You should be posting over in the FM Integration section – you’ll need to adjust your Conversion settings and force an update to suck in the FM TOC and IX

  • Automate Creation of Folder based on Filename

    Hi,
    I am a total newbie to Automator, and although I have some programming background, I have not wrapped my brain around how this wonderful tool works yet. I need to perform a task on several hundred files and I need to do it soon, so no time to learn and play with Automator right now.
    I was wondering if someone can give me a true step by step instructions for creating a script that will do the following:
    This is how I would like the flow to behave:
    1. I select a file and run the script (hopefully based on a keystroke). The script will then:
    2. Create a new folder in the same directory as the file.
    3. Name the new folder based on the filename (minus the extension) of the above selected file.
    4. Move the selected file into the new folder.
    So basically I am enveloping the selected file in a new folder that is named the same as the file itself (minus the extension).
    Thank you in advance.

    OK, I reworked and tested it, so I think I've got all the oddities found. I wound up just using an AppleScript, since about the only thing Automator was used for was getting Finder Items (and it didn't do so well at that). Paste the script into the Script Editor and save it as an application (make sure the Startup Screen option is unchecked). You can either drop items on it or double-click it, in which case it will prompt for items. Document files are the only things processed, and packages/bundles are handled correctly (getting subfolders will not go into them), so you don't have to worry about things like application bundles and .rtfd files.
    <pre style="
    font-family: Monaco, 'Courier New', Courier, monospace;
    font-size: 10px;
    margin: 0px;
    padding: 5px;
    border: 1px solid #000000;
    width: 720px; height: 340px;
    color: #000000;
    background-color: #FFDDFF;
    overflow: auto;"
    title="this text can be pasted into the Script Editor">
    -- make new folders with the name of document files, then move them into their respective new folders
    -- the following properties affect the operation of the script
    property GetFiles : false -- get individual files?  true chooses files, false chooses folders
    property GetSubFolders : true -- get contents of subfolders?  true gets contents of subfolders, false skips them
    property DestinationFolder : "" -- if a folder path is specified, it is used as the destination for file moves
    on run -- application double-clicked
    if GetFiles then
    choose file with prompt "Choose a file:" default location (path to desktop) with multiple selections allowed without invisibles
    else
    choose folder with prompt "Choose a folder:" default location (path to desktop) with multiple selections allowed without invisibles
    end if
    open the result
    end run
    on open TheItems -- items dropped onto the application
    if DestinationFolder is not missing value then try -- verify destination path
    DestinationFolder as alias
    on error
    set DestinationFolder to (choose folder with prompt "Invalid destination folder path - where do you want to move the items?")
    end try
    set SkippedItems to {} -- this will be a list of skipped items (errors)
    set TheFiles to {} -- this will be a list of items to process
    repeat with AnItem in TheItems -- expand folders
    set AnItem to the contents of AnItem
    set FileInfo to (info for AnItem)
    if (folder of FileInfo) and not (package folder of FileInfo) then -- a folder
    if GetSubFolders then
    repeat with SubItem in (ListFiles from AnItem)
    set the end of TheFiles to (contents of SubItem)
    end repeat
    else
    tell application "Finder" to (get files of AnItem) as alias list
    set TheFiles to TheFiles & the result
    end if
    else
    set the end of TheFiles to AnItem
    end if
    end repeat
    repeat with MyFile in TheFiles -- do stuff with the resulting items
    set {TheClass, TheName, TheExtension, TheContainer} to (GetTheNames from MyFile)
    if TheClass is «class docf» then try -- just document files
    tell application "Finder"
    if DestinationFolder is not missing value then
    make new folder at DestinationFolder with properties {name:TheName}
    else
    make new folder at TheContainer with properties {name:TheName}
    end if
    move MyFile to the result
    end tell
    on error ErrorMessage -- the folder already exists, permissions, etc
    log ErrorMessage
    set the end of SkippedItems to (TheName & TheExtension)
    -- set the end of SkippedItems to (AnItem as text) -- the full file path
    end try
    end repeat
    if SkippedItems is not {} then -- handle skipped items
    set AlertText to "Error with moving files to folders"
    if (count SkippedItems) is greater than 1 then
    set TheMessage to ((count SkippedItems) as text) & space & "items were skipped:"
    else
    set TheMessage to "1 " & "item was skipped:"
    end if
    set {TempTID, AppleScript's text item delimiters} to {AppleScript's text item delimiters, return}
    set {SkippedItems, AppleScript's text item delimiters} to {SkippedItems as text, TempTID}
    display alert AlertText message TheMessage & return & SkippedItems
    end if
    end open
    to GetTheNames from SomeFile
    get a class, name, extension, and container from a file path
    parameters - SomeFile [mixed]: a file path
    returns [list] - item 1 [constant]: the class of the file object
    item 2 [text]: the name of the file
            item 3 [text]: the .extension (if no extension, the value returned is "")
    item 4 [alias]: the containing folder of the file
    set SomeFile to SomeFile as alias -- the Finder likes aliases
    tell application "Finder"
    set TheClass to class of (get properties of SomeFile)
    set TheName to name of SomeFile
    set TheExtension to name extension of SomeFile
    if TheExtension is in {missing value, ""} then
    set TheExtension to ""
    else
    set TheExtension to "." & TheExtension
    end if
    set TheName to text 1 thru -((count TheExtension) + 1) of TheName -- just the name part
    set TheContainer to (container of SomeFile) as alias
    end tell
    return {TheClass, TheName, TheExtension, TheContainer}
    end GetTheNames
    to ListFiles from SomeItem
    return a list of files contained in SomeItem, drilling down into subfolders (not packages)
    parameters - SomeItem [mixed]: the item to get the contents of
      returns [list]: a list of aliases
    set {FilesList, SomeItem} to {{}, SomeItem as text}
    set FileInfo to (info for SomeItem as alias)
    if (folder of FileInfo) and not (package folder of FileInfo) then -- a folder
    try
    tell application "Finder" to set SubItems to (items of folder SomeItem)
    on error
    return {}
    end try
    repeat with AnItem in SubItems -- drill down
    set FilesList to FilesList & (ListFiles from AnItem)
    end repeat
    else
    set the end of FilesList to (SomeItem as alias)
    end if
    return FilesList
    end ListFiles
    </pre>

  • Error In ccBPM : Correlation Error

    Hi All,
    We are working on a scenario where in the first received structure in ccBPM waits second structure using correlation.
    And further we need to merge both of them together using transformation (Message Mapping) inside ccBPM . Interestingly in our case both the messages are choosen from earlier stages of the ccBPM  for merging  . Now we are facing correlation error saying "correlation is to be activated in the proceeding step" which we have already done . So the ccBPM is still under error .
    Please help us on the same .
    Here is the approximate representation of ccBPM  steps :-
    1.) Start--->Receive>  Other BPM steps > <1st message to be merged>-><2nd message to be merged>----->Transformation for merging -
    > end
    The 1st message and the 2nd meesage is what we are merging inside ccBPM .The messagesare from the previous steps of the ccBPM. We are not able to correlate the messages.
    Regards
    Nishant

    u have multiple files, then every file will initiate a BPM instance.
    And in turn every BPM instance is waiting for a message ,messages coming  are not able to go for exact BPM instance..
    FYI , no correlation on the messages.... (i guess)
    @but you need to give clear picture of whats happening with all the steps and business requirement before anybody can comment on this.
    1) is this issue at co relating the return message or in merging the co related message....

  • Routing Message based on FileName

    Hi all,
              I hav a scenario where I need to route the file based on the file name.
             for eg: if the 10th char of the filename is 'A' then it has to be placed in Location 1
                          if the 10th char of the filename is 'B' then it has to be placed in location  2.
         Both sender and receiver are file adapters.
         I thought of using condition in Intrface Determination (Context object) , but got stuck since I have to comapare only the 10th char not all the characters since other characters are dynamic.
    Note: This is a pass through Interface and no mapping is involved.
    Thanks,
    Siva

    Hi,
          I am using Context Object functionality for routing purpose.
         In XPath we can use SubString Function but we can not use the same Function in Context Object.
         Is there any workaround for this.
    Thanks,
    Siva

  • CcBPM Correlation - Conversion Id

    Hello,
    so far, e.g. before SP12 I used the field "conversionid" in my ccBPM to connect two messages together. My scenario is that I receive data for an IDOC from a web service which I send via the IDOC adapter to R/3 and then I send an ALEAUD back to my ccBPM which answers the SOAP call. I use the S/A Bridge for that. ws -> xi -> idoc -> r/3 -> idoc -> xi -> ws.
    I used the conversionid which was the same on the sending the idoc and the receiving of the ALEAUD. Now after SP12 it is empty.
    What have other people used to correlate two message other then payload information as the ALEAUD does not have a great payload.
    I sure could extend the ALEAUD to send the right fields back but I like that the ccBPM has its own connection fields you could use (At least you can select them in the correlation editor).
    Thanks
    Stefan

    Hi Stefan.,
    Which of the following is the conversatino id?
    versionMinor="000" SOAP:mustUnderstand="1" wsu:Id="wsuid-main-92ABE13F5C59AB7FE10000000A1551F7">
    open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" wsu:Id="wsuid-manifest-5CABE13F5C59AB7FE10000000A1551F7">
    - <SAP:Payload xlink:href="cid:[email protected]">
    these are the only id's i can see in header apart from message id. so can you please tell me where and how can i get conversation id??
    Thank you
    Indrasena

  • Set Custom4 based on filename

    Hi, I need to overwrite the custom4 in the file which is imported to FDM based on the last 6 digits in the filename.
    vCustom4 = right(strFile,6)
    These 6 digits then need to be set as Custom4 (and replace whatever there might be as c4 already in the file).
    Where and how do I do this?
    Thanks

    This substitution can be done in one of 2 ways:
    1) Via an import script attached to the C4 dimension
    2) In a conditional map attached to the C4 dimension
    If processing large volumes of data option1 is probably the most performant

  • Automating sychronization based on filename

    This issue was already posted in the forum and I have been asked to send a feature request.
    Hello,
    I shot using RAW+JPEG and I import both in Lightroom. During the importation I rename my file so both RAW and JPEG have the same unique name. I develop my RAW in LR but I would like to automate a few things regarding the linked JPEG:
    automate the staking of the RAW and JPEG and put the RAW in the 1st place of the stack. I know there is an auto-stack feature using some time lag (in my case I can put 1 second) but unfortunateley the auto-stack is not based on the filename (regardless of the extension it's the same filename...) and usually puts my JPEG in the 1st place.
    Usually I crop my RAW file. I would like to automate the cropping on the linked JPEG file. Auto-sync might be the correct answer but I have a huge number of pictures and I cannot select each time the RAW and JPEG and auto-sync. So what I would like is some auto-sync using again the filename as a selection input.
    I general, it's too bad that LR does not consider the JPEG as linked to the RAW. If we take RAW+JPEG it's because the JPEG has all the camera settings (colors, optimization of high or low light, etc.) and it can be a great help when you want in LR develop you RAW has if it was from your camera processing...
    Bye.

    This issue was already posted in the forum and I have been asked to send a feature request.
    Hello,
    I shot using RAW+JPEG and I import both in Lightroom. During the importation I rename my file so both RAW and JPEG have the same unique name. I develop my RAW in LR but I would like to automate a few things regarding the linked JPEG:
    automate the staking of the RAW and JPEG and put the RAW in the 1st place of the stack. I know there is an auto-stack feature using some time lag (in my case I can put 1 second) but unfortunateley the auto-stack is not based on the filename (regardless of the extension it's the same filename...) and usually puts my JPEG in the 1st place.
    Usually I crop my RAW file. I would like to automate the cropping on the linked JPEG file. Auto-sync might be the correct answer but I have a huge number of pictures and I cannot select each time the RAW and JPEG and auto-sync. So what I would like is some auto-sync using again the filename as a selection input.
    I general, it's too bad that LR does not consider the JPEG as linked to the RAW. If we take RAW+JPEG it's because the JPEG has all the camera settings (colors, optimization of high or low light, etc.) and it can be a great help when you want in LR develop you RAW has if it was from your camera processing...
    Bye.

  • Need help creating a folder action for creating folders based on filenames.

    I want to create a folder action that will monitor a folder and every time a file is added to the folder it will create a directory using the filename (minus the extension) and move the file the that directory

    on run {input, parameters} -- create folders from file names and move
      set output to {} -- this will be a list of the moved files
      repeat with anItem in the input -- step through each item in the input
        set {theContainer, theName, theExtension} to (getTheNames from anItem)
        try
          set destination to (makeNewFolder for theName at theContainer)
          tell application "Finder"
            move anItem to destination
            set the end of the output to the result as alias -- success
          end tell
        on error errorMessage -- duplicate name, permissions, etc
          log errorMessage
          # handle errors if desired - just skip for now
        end try
      end repeat
      return the output -- pass on the results to following actions
    end run
    to getTheNames from someItem -- get a container, name, and extension from a file item
      tell application "System Events" to tell disk item (someItem as text)
        set theContainer to the path of the container
        set {theName, theExtension} to {name, name extension}
      end tell
      if theExtension is not "" then
        set theName to text 1 thru -((count theExtension) + 2) of theName -- just the name part
        set theExtension to "." & theExtension
      end if
      return {theContainer, theName, theExtension}
    end getTheNames
    to makeNewFolder for theChild at theParent -- make a new child folder at the parent location if it doesn't already exist
      set theParent to theParent as text
      if theParent begins with "/" then set theParent to theParent as POSIX file as text
      try
        return (theParent & theChild) as alias
      on error errorMessage -- no folder
        log errorMessage
        tell application "Finder" to make new folder at theParent with properties {name:theChild}
        return the result as alias
      end try
    end makeNewFolder
    This script almost does what I need except for the fact that it screws up on files with periods in them
    for example
    1.2.3.4.txt
    will create the directorys 1, 2, 3, and 4 instead of 1.2.3.4

  • List of the Files in a Directory based on Filename filter

    Hi,
    Do any one has an idea about fileName filter Usage.
    Ex: in UNIX: $ ls -l *.java gives the list of the java files in the directory.
    To acheive this we FilenameFilter. please let me know if anyone has any idea about this.
    Regard's
    Kartheek

    All of the answers to these questions, and more, are a mouse-click away. You can't develop a Java application without referring to the core Java API javadoc:
    http://java.sun.com/j2se/1.4.2/docs/api/index.html
    Your current task is to find the following classes and methods, and make sure you understand what they do:
    java.io.File :: list(FilenameFilter filter)
    java.io.FilenameFilter :: accept(File dir, String name)
    java.lang.String :: endsWith(String s)
    Once you get done with those, I'm sure there's a lot more you'll want to look up.
    Good luck.

  • Create folders and subfolders based on filename

    I am trying to find a way to put patient information into folders based on their file names.  For example, the x-ray of a patient would be named "johndoe|xray|.pdf" and I need a way to do the following automatically:
    Look for "JohnDoe" folder and create one if it doesn't exist
    Look for an "XRay" subfolder (inside of JohnDoe) and create it if it doesn't exist
    Put the file into the subfolder.
    The trigger for this would be the insertion of the document into a specific folder.  I am not sure if Applescript or a Terminal command would be the best way to do this.

    $srv = get-content .\servers.txt
    $blok = { ##scriptblock
    #old paths
    $strPathOld1 = "F:\Share"
    $strPathOld2 = "G:\Share2"
    #new path
    $strPathNew = "M:\ShareNew"
    #icacls permissions
    $strGrant = "/grant"
    $strRemove = "/remove"
    $strIcaclsPrms1 = ":(OI)(CI)(F)"
    $strIcaclsPrms2 = ":(OI)(CI)(IO)(F)"
    $strIcaclsPrms3 = ":(OI)(CI)(RX)"
    $strIcaclsPrms4 = ":(RX)"
    $strIcaclsPrms5 = ":(OI)(CI)(M)"
    $strIcaclsPrms6 = ":(OI)(CI)(RX,W)"
    $strIcaclsPrms7 = ":(OI)(CI)(RX,W,DC)"
    #users, groups ...
    $KOMU1 = "domain\account1"
    $KOMU2 = "domain\group1"
    ## Deleting old shares
    Invoke-Expression -Command ('net share $strPathOld1 "/delete" "/y"')
    Invoke-Expression -Command ('net share $strPathOld2 "/delete" "/y"')
    ## Removing Quotas
    Invoke-Expression -Command ('dirquota quota delete /path:$strPathOld2 /quiet')
    ## Create new direktory
    Invoke-Expression -Command ('New-Item -Path $strPathNew -ItemType "directory"')
    ## Create new share
    Invoke-Expression -Command ('net share "Share1=$strPathNew" "/grant:Everyone,FULL"')
    ## Remove permissions ... (example)
    Invoke-Expression -Command ('icacls $strPathNew $strRemove "${KOMU2}"')
    ## Grant permission
    Invoke-Expression -Command ('icacls $strPathNew $strGrant "${KOMU6}${strIcaclsPrms1}"')
    Invoke-Expression -Command ('icacls $strPathNew $strGrant "${KOMU7}${strIcaclsPrms1}"')
    ## Remove direktory
    Invoke-Expression -Command ('remove-Item -Path $strPathOld2 -recurse -force')
    ## set new quota
    Invoke-Expression -Command ('dirquota quota add /path:G:\Share2 /limit:50gb /type:hard /status:enabled /overwrite')
    ## Running script
    foreach ($s in $srv)
    if ((Test-Connection -ComputerName $s -Quiet) -eq $true)
    Echo $s
    Invoke-Command -ComputerName $s -ScriptBlock $blok
    else
    $s + " - connection failure"
    I use this one for all tasks you are looking for.    Hope this helps

  • Trying to create an Applecreate to rename files into folders based on filename

    I am trying to create an AppleScript that will take a file (a.b.c.txt forexample) and create a directory from the filename minusextensionand then move the file into that directory
    ie.a.b.c>a.b.c.txt
    I found this script from red_menace
    {input, parameters} -- create folders from file names and move
      set output to {} -- this will be a list of the moved files
      repeat with anItem in the input -- step through each item in the input
        set {theContainer, theName, theExtension} to (getTheNames from anItem)
        try
          set destination to (makeNewFolder for theName at theContainer)
          tell application "Finder"
            move anItem to destination
            set the end of the output to the result as alias -- success
          end tell
        on error errorMessage -- duplicate name, permissions, etc
          log errorMessage
          # handle errors if desired - just skip for now
        end try
      end repeat
      return the output -- pass on the results to following actions
    end run
    to getTheNames from someItem -- get a container, name, and extension from a file item
      tell application "System Events" to tell disk item (someItem as text)
        set theContainer to the path of the container
        set {theName, theExtension} to {name, name extension}
      end tell
      if theExtension is not "" then
        set theName to text 1 thru -((count theExtension) + 2) of theName -- just the name part
        set theExtension to "." & theExtension
      end if
      return {theContainer, theName, theExtension}
    end getTheNames
    to makeNewFolder for theChild at theParent -- make a new child folder at the parent location if it doesn't already exist
      set theParent to theParent as text
      if theParent begins with "/" then set theParent to theParent as POSIX file as text
      try
        return (theParent & theChild) as alias
      on error errorMessage -- no folder
        log errorMessage
        tell application "Finder" to make new folder at theParent with properties {name:theChild}
        return the result as alias
      end try
    end makeNewFolder
    But my problem with this script is that it does messes up if the file name includes the period, from my example, the listed script will make directorys a, b, and c instead of a.b.c

    You can use this Automator Workflow:
    for f in "$@"
    do
      d=${f%.*}
      if [ ! -d "$d" ]; then 
           mkdir "$d"
      fi
      mv "$f" "$d"
    done

Maybe you are looking for

  • HT1933 Unable to hear all the music I have purchased on my iPhone iTunes account on my IPhone 5.

    I am unable to hear the songs I purchased on my iPhone 5. The songs skip. I have already had my speaker replaced. Now most of my purchased music will not play.

  • PL/SQL Automatic Constraint Handler(Code)

    For those interested... I created the following database code that automatically does the constraint check/return error message for you. You could even take this a step further and create your own message repository... This guy even grabs/checks for

  • Handling special characters in XML

    Hi, I am using Oracle 10g 'XMLType' datatype to store XML files. Before storing I parse the XML document using Java Xerces Parser. If it parses successfuly, then I perform some business rule execution based on XML file which was parsed. So till this

  • Context Sensitive authorization implement in 4.6C

    Dear all, Is there any way to implement context sensitive authorization in 4.6C? Something like P_ORGINCON object in the newer version. I know the easiest way is to create two IDs for one user; one with each respective role/ structural authorization.

  • Moto 360 Watch.!

    A neat concept in the form of a Watch from Motorola is coming Soon to Verizon according to Following Pre-ordering is open and the Watch will ship to new owners around the 11 of March this Info is Via Droid Life, The Watch is really nice Looking and w