Generating a custom named csv in Delimited Text Driver


Hi ,

I am trying to develop a delimited text driver that will listen to add /
modify events and generate a csv file output. I have used the default
configurations in driver and has defined the schema and the filter for
the required attributes.

Whenever there is a add event we are able to get a .csv file (for the
defined attributes) as output, but the file name is a timestamp.
Something like 185914481233.csv. I am not sure from where this name is
getting generated.

My requirement is if the event is

1. for create user , the csv file generated should have a name as
c-username-timestamp.csv
2. for update user , the csv file generated should have a name as
U-username-timestamp.csv

Can you please let me know how i can do this customization for file name
?


--
kalariviswa
------------------------------------------------------------------------
kalariviswa's Profile: https://forums.netiq.com/member.php?userid=9296
View this thread: https://forums.netiq.com/showthread.php?t=56218

Parents Reply Children
  • al b wrote:

    > 2. Use ecmascript file-access functions and have complete control for
    > file operations.
    > I used this method for generate "custom" logs for on-boarding driver
    > (generated file name included cn and date information).
    >
    >
    > We have number of ECMA functions with similar functionality.
    > > function writeFile(fileName, contentString)
    > > function fileRead(filepath)
    > > function ReadFromFile(fileName)
    > > function appendToFile(fileName, text)

    >


    Just a note: not all of these are thread-safe and thus extreme care
    should be used when calling these functions from multiple drivers or
    even from publisher and subscriber channel in the same driver.