Is "option(recompile)" more efficient than "with recompile"?
Say you have a stored procedure about 700 lines long, maybe twenty big selects populating a temp table, with some logic to choose about half of them for any set of parameters. If you say "with recompile" then all 700 lines are recompiled each call. If you say "option(recompile)" on all the big statements then just about half the lines will be recompiled each time.
Right?
Or, is "with recompile" smart enough that it acts pretty much the same way?
Thanks,
Josh