cancel
Showing results for 
Search instead for 
Did you mean: 

ImpEx Export CronJob - How to set Filename and destination Folder?

Former Member
0 Kudos

Hi all, I'm running a Hybris 6.0 and I need to export some content to a plain CSV file in a particular folder with a particular naming prefix. Using the Backoffice tools I created a Script containing the Impex and then created the ImpEx-Export CronJob setting: - the ImpEx content pointing to the Script created, - the Mode to "Export no re-import", - Export as singleFile "true". This generates a "ImpExCSV_.csv" file in the "hybris\temp\hybris" folder; this filename is set regardles of what I put inside the Impex setTargetFile (e.g. "Orders.csv").

I would need your guidance in order to set the csv filename keeping the hash or some timestamp (e.g. to "Orders_.csv), and to set another destination folder.

I already revised all the information available online and I still can't find the right solution. There is an old question posted here: "Impex export filename and location" https://answers.sap.com/questions/12758761/impex-export-filename-and-location.html However the reply is not very clear.

Thanks and Regards, Max

Former Member
0 Kudos

Hello Max, Did you find an answer, because I faced the the same issue, and do not know how to resolve it.

Former Member
0 Kudos

Hi Max,

Did you find any solution for this ? Even i have same requirement. I am facing null pointer when i try to do setTargetFile("somename.csv")

Thanks Sandeep

Former Member
0 Kudos

Hi Sandeep, unfortunately I did not continue developing this and I did not get any suitable reply. If you are able to find a workaround, please share it with us.

Regards, Max

Former Member
0 Kudos

Thanks for the reply. Sure Max. Will update something on my findings sooner

Former Member
0 Kudos

Hi Max,

The solution is working now. setTargetFile ends up having some null pointer issues.

Use file copy instead and get the things working.

Cheers Sandeep

Former Member
0 Kudos

Quick fix is : use the provided OOB way of export and then use filecopy to move to custom location :)

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

- Did you get solution to this ?

Former Member
0 Kudos

Hi Max,

You can refer to https://help.hybris.com/6.0.0/hcd/8bedf975866910148e32dfd90cf35c23.html

There are some Advanced Settings Tab can be used.

Thanks!

Best Regards

Former Member
0 Kudos

Hi Haitao, can you please be more specific?

Thanks and regards, Max