SQL References

SQL References

SQL is a standard language for storing, manipulating, and retrieving data in databases.

...see more

The following SQL statement shows how to copy the data from one column to another.

It will replace any existing values in the destination column, so be sure to know exactly what you’re doing and use the WHERE statement to minimize updates (e.g., WHERE destination_column IS NULL ).

UPDATE table 
SET destination_column = source_column
WHERE destination_column IS NULL
...see more

The SQL UPDATE Statement

The UPDATE statement is used to modify the existing records in a table.

UPDATE Syntax

UPDATE table_name
SET column1 = value1, column2 = value2, ...
WHERE condition;
 

SQL SET Keyword

The SET command is used with UPDATE to specify which columns and values should be updated in a table.

The following SQL updates the first category (CategoryID = 1) with a new Name and a new Type:

Example

UPDATE Category
SET Name = 'Article', Type = 'Premium'
WHERE CategoryID = 1;
 
Add to Set
  • .NET
  • Agile
  • AI
  • ASP.NET Core
  • Azure
  • C#
  • Cloud Computing
  • CSS
  • EF Core
  • HTML
  • JavaScript
  • Microsoft Entra
  • PowerShell
  • Quotes
  • React
  • Security
  • Software Development
  • SQL References
  • Technologies
  • Testing
  • Visual Studio
  • Windows
 
Sets