SELECT TOP n

  • In SQL 2000 Enterprise Manager (not Query Analyzer!) you can right mouse click on a table and OPEN, RETURN TOP "n" rows.   THEN you can interactively CHANGE the cell (or cells) content of a row.

    In SQL 2005, 3 questions:

    1. Can you do a SELECT TOP "n" rows without using Mgmt Studios Object Explorer?

    2. How do you change the contents of a single cell on a row without performing an explicit UPDATE statement from Object Explorer?

    3. In Object Explorer, how do you CLEAR the contents of the RESULTS PANE to free up real estate on the screen?

    -thx in advance 

    BT
  • Hi Bill,

    I can't see that you can do a SELECT TOP n like you could in 2000, but you can do this:

    Right-click  tablename> OPEN TABLE

    Right-click in RESULTS PANE > PANE > SQL

    Change the SQL to read SELECT TOP n .....

    You can edit individual cells here and the change is reflected in the table.

    To clear the contents of the results pane, Right-click > CLEAR RESULTS or shut the whole RESULTS pane by using the little 'X' in the top right hand corner

    Is that what you were after or have I got the wrong end of the stick?

  • Tim - thanks for the excellent reply.  All 3 issues have been answered. 

    Hey, ANY recommendations on speeding up the Connection time to SQL Server 2005? 

    Whenever I do an OPEN or click the 'NEW QUERY' button on the toolbar, the CONNECTION to Server/DB window fires up and the connection takes 10-30 seconds !!  As opposed to Query Analyzer (in 2000) which allowed you to quickly render new Query windows instantaneously.

    BT
  • re: -

    3. In Object Explorer, how do you CLEAR the contents of the RESULTS PANE to free up real estate on the screen

    There is also a button on the 'Query Designer' toolbar for hiding the results pane (CTRL + 4 does the same thing)

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply