Based on this link http://msdn.microsoft.com/en-us/library/ms170572.aspx, I successfully execute the SQL that I coded in the SQL file via the following code:
sqlcmd -S myServer\instanceName -i C:\myScript.sql
Now instead of executing a SELECT operation, I would like to have UPDATE operation. I'm wondering how to modify the above code so that it accept parameter and this parameter will be used in myScript.sql?
My sample UPDATE operation will be expected to be something like below:
UPDATE someColumn FROM someTable where tableID = @tableID;
So from the command, I will provide a tableID