I want to run a job every hour which calls a stored proc using osql and apppends the results to a text file.
But it always overwrites the previous results. Is there a way of getting osql to append the results instead?Originally posted by mwilkes
I want to run a job every hour which calls a stored proc using osql and apppends the results to a text file.
But it always overwrites the previous results. Is there a way of getting osql to append the results instead?
Good old DOS, you should use batch file to append OSQL results into existing text file, named differently than the one used in OSQL output, something like:
osql ... > Osql.Txt
Type Osql.Txt >> FinalResult.Txt
Where FinalResult.Txt contains all, appended results.
Cheers, Marin
Saturday, February 25, 2012
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment