sql-serverssmssql-server-2008

How to alter SQL in "Edit Top 200 Rows" in SSMS 2008


In SQL Server 2008 Management Studio, when I right click on a database table and choose Select Top 100 Rows, I can then e.g. easily add a ORDER BY statement to the SQL. That works fine.

But when I do choose Edit Top 200 Rows, I don't have the ability to alter the SQL (which makes it hard to find and edit a record just added in the 10,000 that are there.

I am quite sure I was able to do this in SQL Server 2000.

Is there any way in SMSS 2008 to alter the way the records are displayed when editing records?


Solution

  • If you right click on any result of "Edit Top 200 Rows" query in SSMS you will see the option "Pane -> SQL". It then shows the SQL Query that was run, which you can edit as you wish.

    It's the SQL button on the following image: enter image description here

    In SMSS 2012 and 2008, you can use Ctrl+3 to quickly get there.