Quantcast
Channel: SQL Server Integration Services forum
Viewing all articles
Browse latest Browse all 24688

SSIS variable expression

$
0
0

Below is my ssis variable expression within a data flow task. User::comp variable is from the loop.  I need to pass this into the query below.  The and condition (and date_added >''2018-10-05') only needs to apply only when comp =49.  It kept getting the syntax error from it, can you help please, Thanks

@[User::comp]  == 49 ?
"select *
from myorders
where comp_id ="+ @[User::comp] +" 
and date_added >''2018-10-05''" ? 
"select *
from myorders
where comp_id ="+ @[User::comp] +""


Viewing all articles
Browse latest Browse all 24688

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>