please help SSIS
I have the following as sql query when using an excel connection
August being the tab name
select * from [August$A14:N14]
But i want it to open on a specific month only for example tab August (the tab name will change per month when i run the package hence trying to use the variable)
and rows A14:N14
i have tried something like the following
declare @monthname as varchar(20)= DATENAME(month,DATEADD(MONTH,
DATEDIFF(MONTH, 0, GETDATE())+2, 0))
select * from [@monthname$A14:N14]
but I cannot get it to work
any suggestions please
update: i have tried variable method below too - i get invalid bracketing error
select * from [@(User::vMonth)$A14:N14]
please help