I have inherited an SSIS package that selects data by SQL command in OLE DB Source. Have added additional User Variable for Location ID, now in some cases that ID will have a value and other it will have a default value of zero. Which means the query does not need location ID check in the WHERE clause. I need to check that User Variable to determine when added LocationID to the query. I was not able to successfully add an if statement is the SQL command editor window.
Thanks for any guidance!