Global web icon
stackoverflow.com
https://stackoverflow.com/questions/1293330/how-ca…
How can I do an UPDATE statement with JOIN in SQL Server?
This was an example, but the point is as Eric said in How can I do an UPDATE statement with JOIN in SQL Server?. You need to add an UPDATE statement at first with the full address of all tables to join with, and then add the SET statement.
Global web icon
stackoverflow.com
https://stackoverflow.com/questions/33205087/sql-u…
SQL UPDATE WHERE IN (List) or UPDATE each individually?
UPDATE table1 SET somecolumn = 'someVal' WHERE ID IN (SELECT ID FROM @definedTable); In the above, @definedTable is a SQL 'User Defined Table Type', where the data inside comes through to a stored procedure as (in C#) type SqlDbType.Structured People are asking how the ID's come in: ID's are in a List<string> in the code, and are used for other things in the code before then being sent to a ...
Global web icon
stackoverflow.com
https://stackoverflow.com/questions/982919/sql-upd…
sql server - SQL update query using joins - Stack Overflow
If you are using SQL Server you can update one table from other table without specifying a join and simply link the two tables from the where clause. This makes a much simpler SQL query:
Global web icon
stackoverflow.com
https://stackoverflow.com/questions/20255138/sql-u…
SQL - Update multiple records in one query - Stack Overflow
I have table - config. Schema: config_name | config_value And I would like to update multiple records in one query. I try like that: UPDATE config SET t1.config_value = 'value' , t2.config_va...
Global web icon
stackoverflow.com
https://stackoverflow.com/questions/9079617/update…
sql server - Update multiple columns in SQL - Stack Overflow
262 Is there a way to update multiple columns in SQL server the same way an insert statement is used? Something like:
Global web icon
stackoverflow.com
https://stackoverflow.com/questions/224732/sql-upd…
SQL Update from One Table to Another Based on a ID Match
Just a note on this solution, UPDATE...FROM is proprietary therefore, if you cannot use the MERGE statement because you are using SQL 2005 or earlier, this is an ANSI-compliant method of performing updates with a table source in MSSQL.
Global web icon
stackoverflow.com
https://stackoverflow.com/questions/5036918/update…
sql - update one table with data from another - Stack Overflow
I'll like to add: for Postgresql, the syntax is slightly different update a set field1 = concat_ws(' ',field1, table2.middle_name, table2.first_name) from table2 where a.id = table2.fieldX; Just added some funtions to show what is possible.
Global web icon
stackoverflow.com
https://stackoverflow.com/questions/14781999/remov…
Remove Trailing Spaces and Update in Columns in SQL Server
I have trailing spaces in a column in a SQL Server table called Company Name. All data in this column has trailing spaces. I want to remove all those, and I want to have the data without any trai...
Global web icon
stackoverflow.com
https://stackoverflow.com/questions/8930151/how-to…
How to handle-escape both single and double quotes in an SQL-Update ...
I have solved a similar problem by first importing the text into an excel spreadsheet, then using the Substitute function to replace both the single and double quotes as required by SQL Server, eg.
Global web icon
stackoverflow.com
https://stackoverflow.com/questions/13881649/updat…
sql - update statement using nested query - Stack Overflow
update statement using nested query Asked 12 years, 11 months ago Modified 3 years, 2 months ago Viewed 105k times