- Posts: 25
- Thank you received: 0
Can I use variables in the 'sql after' tab of MS SQL writer?
- JohnIngles
- Topic Author
- Offline
- Junior Member
-
Less
More
3 years 7 months ago - 3 years 7 months ago #19756
by JohnIngles
Say if I set variable <FileDate> = 2020-02-28, can I then use it in the "SQL After"
UPDATE table1
SET table1.[End_Date]=<FileDate>
from table1 atr
left outer join table2 tmp
on atr.URN = tmp.URN
where tmp.URN is NULL;
UPDATE table1
SET table1.[End_Date]=<FileDate>
from table1 atr
left outer join table2 tmp
on atr.URN = tmp.URN
where tmp.URN is NULL;
Last edit: 3 years 7 months ago by JohnIngles.
Please Log in or Create an account to join the conversation.
- Peter.Jonson
-
- Offline
- Platinum Member
-
3 years 7 months ago #19757
by Peter.Jonson
Peter Jonson
ETL Developer
Replied by Peter.Jonson on topic Can I use variables in the 'sql after' tab of MS SQL writer?
That should work.
Remember all variables are strings so put them in quotes when necessary
Remember all variables are strings so put them in quotes when necessary
Peter Jonson
ETL Developer
Please Log in or Create an account to join the conversation.