There is an option to edit rows in a grid - first 200 by default. In Tools -> Options -> Sql Server Object Explorer, you can set the value for "Edit Top N rows".

I have a table with 200000 rows. What I need to do is edit some of those elements that are almost at the end of the table. I can't set this to "Edit Top 200000 rows" because it will be just too much. However, what I'd like to do is to constraint what is shown in the edit grid - if possible by the Where clause.

For example "Edit Top 500 rows, where ID > 16000". This would be some few hundreds rows so it's ok.

Is this possible in any way, or do I have to write SQL code to update the rows?


Ok, I have found out the answer to this.

If I right-click on the grid header, I can select Pane -> SQL. This shows the SQL statement used to fill the grid. I can add Where constraints there.

It's very easy solution, but I somehow missed that pane.

  • There is also the same button on the toolbar. – Kornelije Petak Oct 28 '11 at 8:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.