Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 299
  • Last Modified:

SQL 2008 R2 - how to update a value ?

Hi, I am total newbie in SQL statements, and need some help in updating some values.

As I understand, SQL 2008 R2 does not have any GUI it self to update or change values. You need to create T-SQL statements/queries.

I have found some commercial web-based applications, but they are pretty expensive and I just need to change 3 simple values in 3 different tables. Going to hard way and learn T-SQL from the beginning, is not an option, I simply have no time for it.

Can anyone give me a simple example of a query that updates the value a table?
For example:
db_name: TestDB

Only 3 columnds:
Id
Member Name
Member value

I need to change a value in the Member Value column WHERE Id=101 from (just an example) 20 to 10.

Or if there exists an option to edit it directly, would be even better (I am getting too lazy after using phpMyAdmin for some years now... ) :)
0
xcomiii
Asked:
xcomiii
1 Solution
 
peeaCommented:
> As I understand, SQL 2008 R2 does not have any GUI it self to update or change values. You need to create T-SQL statements/queries.

You may actually edit some values under SQL Server Management Studio directly, as shown below with my SQL Server 2005.

SQL Server Management Studio to edit opened table
0
 
Ronak PatelCommented:
here is the query syntax for update value in data table:


UPDATE [TableName]
SET  MemberValue = '10'
WHERE Id = 101

Open in new window

0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now