I'm new here so please bear with me. I'm not sure how to ask this question so I have not done a search yet.
I have a proc that creates select statements on the fly from a feeder metadata table for ten tables at a time, all the time. Until now everything was on one server. Now some of the data tables are on another server, but this is not a problem.
There are some times when one of the tables is missing and the proc throws an error (as it should) and stops the execution of the 9 table builds. When it was all on one server, it would always throw an error and continue. Now when it's reading through a linked server it will not continue.
What can I do ? Thank you all.
Hi Brett, Thanks for looking.
The code kicks out 10 select statements and executes each one at a time. In some cases the tables the code is looking for do not exist and SQL throws an error. When I was on the original server (not selected through a linked server) the select would fail and move on to the next select statement (running a cursor). Now when the select fails because the tables don't exist on the linked server, the execution of the proc stops when it reaches the first error instead of moving on. I was hoping it was an option of some sort for the linked server.