I am trying to update a table where the field value is equal to the result of the select statement. I have a table like this:
Type Total
I want to update the above table based on the select result. Here is my code:
update MainTable set [Total
If I run the code as is, it will update all the lines, but I only want to update where Type from select statement is equal to the type from my MainTable. thanks
source share