Hi;
I'm brand spanking new to sqlserver ( nice so far ).
I need to make a simple data change across a list of tables.
Basically replace an old date with a new date.
However, the people I am doing it for want a program that produces
logging of what it does.
I thought I would write a tsql script and run it from query analyzer.
Like I said, the changes are simple, but there are some things my
clients want in the program that I am not sure how to do:
1. excute the *.sql file from query analyzer without pasting the code
into it.
2. connecting to the database in question from the tsql script,
programmatically
3. generating a list of tables that have 4 particular fields and then
programmatically ( tsql ) scrolling that table list searching for
records to be
updated.
4. outputting the table list, & logging records with the old dates
before the script runs and then afterwards.
Any pointers, ideas, or examples will be greatly appreciated
Steve