Hi @delta smith ,
Not sure if you want is like below.
If this meet your requirement, you may use the expression to set the folder name with connection string.
"c:\\sql\\ABC_" + "20_"+
(DATEPART("mm" , GETDATE()) == 2 ? "JAN" :
DATEPART("mm" , GETDATE()) == 3 ? "FEB" :
DATEPART("mm" , GETDATE()) == 4 ? "MAR" :
DATEPART("mm" , GETDATE()) == 5 ? "APR" :
DATEPART("mm" , GETDATE()) == 6 ? "MAY" :
DATEPART("mm" , GETDATE()) == 7 ? "JUN" :
DATEPART("mm" , GETDATE()) == 8 ? "JUL" :
DATEPART("mm" , GETDATE()) == 9 ? "AUG" :
DATEPART("mm" , GETDATE()) == 10 ? "SEP" :
DATEPART("mm" , GETDATE()) == 11? "OCT" :
DATEPART("mm" , GETDATE()) == 12 ? "NOV" :
DATEPART("mm" , GETDATE()) == 1 ? "DEC" :"")+
RIGHT("_" + (DT_STR,4,1252)DATEPART( "yyyy" , getdate() ), 5)+ "_to_20_"+
(DATEPART("mm" , GETDATE()) == 1 ? "JAN" :
DATEPART("mm" , GETDATE()) == 2 ? "FEB" :
DATEPART("mm" , GETDATE()) == 3 ? "MAR" :
DATEPART("mm" , GETDATE()) == 4 ? "APR" :
DATEPART("mm" , GETDATE()) == 5 ? "MAY" :
DATEPART("mm" , GETDATE()) == 6 ? "JUN" :
DATEPART("mm" , GETDATE()) == 7 ? "JUL" :
DATEPART("mm" , GETDATE()) == 8 ? "AUG" :
DATEPART("mm" , GETDATE()) == 9 ? "SEP" :
DATEPART("mm" , GETDATE()) == 10 ? "OCT" :
DATEPART("mm" , GETDATE()) == 11 ? "NOV" :
DATEPART("mm" , GETDATE()) == 12 ? "DEC" :"") +
RIGHT("_" + (DT_STR,4,1252)DATEPART( "yyyy" , getdate() ), 5) +".csv"
Details for your reference:
Regards,
Zoe
If the answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
Hot issues October