syncovery file names

English Support for Syncovery on Windows.
Post Reply
dmcleer
Posts: 2
Joined: Thu May 12, 2022 7:19 pm

syncovery file names

Post by dmcleer »

I am trying to create a path for a file on an FTP site to get downloaded monthly. however one of the folders in the path name will change each month because the folder name is the date those files in that folders where put into FTP. how do you indicate in the path name what the folder name will be when one of the folders names changes each month?

tobias
Posts: 1603
Joined: Tue Mar 31, 2020 7:37 pm

Re: syncovery file names

Post by tobias »

Hello,
you can use variables to construct your path, please see

https://www.syncovery.com/variables/

If the necessary variable does not exist, the path can be created with a PascalScript, please see

https://www.syncovery.com/pascalscript/

Let me know if questions remain!

dmcleer
Posts: 2
Joined: Thu May 12, 2022 7:19 pm

Re: syncovery file names

Post by dmcleer »

I want to give you a little more insight into what i am trying to do. i have looked over the info on the URL's you sent me, however i do not believe they will do what i want it to do. to give you a little idea what i am trying to do is create a job that runs once a month that will download a file from an FTP site to a static folder on one of our servers. below are some specifics of what i am trying to do in syncovery:

The main area i am having an issue with is the left hand side path for under base paths for syncronization:

The path i am putting in is as follows:

sftp://ftps.xxxxx.com/xxxx/20220429/xxxxxxxx

The x's are to shadow out area's for security reasons, but are also the parts of the left side path that are static and do not change from month the month. the 20220429 is the folder that will change each month because the file to download in question is a subfolder of this folder, but this 20220429 will change each month based on the date the file is put into FTP, which if the last day of the month does not fall on a week day will be the last friday of the month. I need a way of indicating this folder so that it will look for only this one folder with its subfolder.

the job i am creating would run on the 1st of each month and have to look at folder from the day before up to 3 or 4 days before. Since the name of the subfolder in that folder will be the same each month if there was a way to set this path to look for that subfolder name of for example 20220429.

not sure if i can use the mask option to look for a specific folder with that subfolder.

tobias
Posts: 1603
Joined: Tue Mar 31, 2020 7:37 pm

Re: syncovery file names

Post by tobias »

Hello,
this can be done with PascalScript.

Or you can let Syncovery scan all folders in

sftp://ftps.xxxxx.com/xxxx

looking for the subfolder xxxxxxxx. To do that, put xxxxxxxx in the Folder Masks via the checkbox "Folder Masks" on the Inclusion Masks tab sheet.

A PascalScript could determine the actual date folder, or it could generate an Inclusion Mask like
/xxxx/YYYYMM??/xxxxxxxx/*

You can strip all the subfolders on the right-hand side by choosing "Flat Right Side" on the Folders tab sheet.

Post Reply