Author: Rohit Umarjikar
Posted: Mon Jul 18, 2016 10:53 am (GMT 5.5)
If you try with what you did then you would know if works or gives error. Explore more on dynamic SQL.
But simple UNION will do what you want in a single cursor and if it gives any type of performance issue then follow Bills way of simply declaring two separate cursors.
Please prefer using code tags.
_________________
Regards,
Rohit Umarjikar
"Some things Man was never meant to know. For everything else, there's Google"
Posted: Mon Jul 18, 2016 10:53 am (GMT 5.5)
If you try with what you did then you would know if works or gives error. Explore more on dynamic SQL.
But simple UNION will do what you want in a single cursor and if it gives any type of performance issue then follow Bills way of simply declaring two separate cursors.
Please prefer using code tags.
_________________
Regards,
Rohit Umarjikar
"Some things Man was never meant to know. For everything else, there's Google"