Hi,
I'd like to know if I'm able to use a CTE inside a transaction block like so:
BEGIN TRANSACTION
WITH CTE .....
SELECT.....etc.
COMMIT TRANSACTION
Any insight will be appreciated.
Thanks,
S
Hi,
I'd like to know if I'm able to use a CTE inside a transaction block like so:
BEGIN TRANSACTION
WITH CTE .....
SELECT.....etc.
COMMIT TRANSACTION
Any insight will be appreciated.
Thanks,
S
Yes, there's absolutely no reason why not. You may need to make sure the statement before the cte is terminated with a semicolon, but that's about all...
No one has followed this question yet.