Just came across a simple yet useful feature of SSMS for creating short cut for commonly used queries. Let’s get started –
1. Open your SSMS and go to Tools -> Options -> Environment -> Keyboard.
2. Type Select * from in Ctrl+3 as shown in the below screen shot –
4. Now go to any database, drag any table and press ctrl+3. You will see all the records which you would have got by writing select * from <tablename>. Make sure the table is selected in the query pane before hitting ctrl+3 otherwise it will show you error like – “Incorrect syntax near ‘from’.’
This will save a lot of time of yours in your project where you need to write “Select * from” thousand times. You just can drag and drop all the tables where you want to do the analysis and execute them as per the need basis. You might also can create 2 short cuts one for “select * from” and another for “select top 10 * from “. You can also use this concept for other commonly used commands like Truncate & Delete, but with utmost care, I personally would avoid them.