Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to edit one specific row in Microsoft SQL Server Management Studio 2008?

In Microsoft SQL Server Management Studio 2008, is there a secret to be able to edit one row based on a key?

There's an option to do "Edit Top 200 Rows", but what if I want to select some other row and edit it in the datagrid? I would rather do that than code an update statement and risk messing up the where clause.

like image 835
NealWalters Avatar asked Nov 13 '09 03:11

NealWalters


People also ask

How do I edit specific rows in SQL Server Management Studio?

Right-click the view and select Edit Top 200 Rows. You may need to modify the SELECT statement in the SQL pane to return the rows to be modified. In the Results pane, locate the row to be changed or deleted. To delete the row, right-click the row and select Delete.

How do I select a specific row in SQL Server?

To select rows using selection symbols for character or graphic data, use the LIKE keyword in a WHERE clause, and the underscore and percent sign as selection symbols. You can create multiple row conditions, and use the AND, OR, or IN keywords to connect the conditions.

How do I select a single line in SSMS?

Shift + Home will do the job perfectly.


1 Answers

Use the "Edit top 200" option, then click on "Show SQL panel", modify your query with your WHERE clause, and execute the query. You'll be able to edit the results.

like image 158
Nestor Avatar answered Oct 03 '22 17:10

Nestor