<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blog.sqlblog.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Using Alt-select in SSMS, Word, and elsewhere</title><link>http://blog.sqlblog.com/blogs/john_paul_cook/archive/2012/09/08/using-alt-select-in-ssms-word-and-elsewhere.aspx</link><description>A surprising number of database people and Windows users in general don’t know about Alt select . This is a Windows technique not unique to SSMS that allows a user to select an arbitrary rectangular region of text and delete it, cut it, or copy it. Where</description><dc:language>en</dc:language><generator>CommunityServer 2.1 SP2 (Build: 61129.1)</generator><item><title>re: Using Alt-select in SSMS, Word, and elsewhere</title><link>http://blog.sqlblog.com/blogs/john_paul_cook/archive/2012/09/08/using-alt-select-in-ssms-word-and-elsewhere.aspx#45095</link><pubDate>Sun, 09 Sep 2012 12:11:49 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:45095</guid><dc:creator>Chris Nelson</dc:creator><description>&lt;p&gt;It may not work in Notepad, but it works in Notepad++ and many other programming editors. I believe it also works in Adobe Acrobat, which makes it useful for monthly budgeting.&lt;/p&gt;
</description></item><item><title>re: Using Alt-select in SSMS, Word, and elsewhere</title><link>http://blog.sqlblog.com/blogs/john_paul_cook/archive/2012/09/08/using-alt-select-in-ssms-word-and-elsewhere.aspx#45236</link><pubDate>Mon, 17 Sep 2012 19:14:29 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:45236</guid><dc:creator>dbaInTraining</dc:creator><description>&lt;p&gt;Thanks for the tip. &amp;nbsp;This will prove helpful.&lt;/p&gt;
</description></item><item><title>re: Using Alt-select in SSMS, Word, and elsewhere</title><link>http://blog.sqlblog.com/blogs/john_paul_cook/archive/2012/09/08/using-alt-select-in-ssms-word-and-elsewhere.aspx#45266</link><pubDate>Tue, 18 Sep 2012 23:52:44 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:45266</guid><dc:creator>Jared Ko</dc:creator><description>&lt;p&gt;Also useful for execution of commented-out code. Usually you'll have some sort of indenting in place such as:&lt;/p&gt;
&lt;p&gt; &amp;nbsp; SELECT DepartmentID&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;, Name&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;, GroupName&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;, ModifiedDate&lt;/p&gt;
&lt;p&gt; &amp;nbsp; FROM HumanResources.Department&lt;/p&gt;
&lt;p&gt;-- WHERE ModifiedDate &amp;gt; '2012/09/17'&lt;/p&gt;
&lt;p&gt;Execute it as a batch and it won't execute the WHERE clause. Hold down ALT and highlight all of the text (including the WHERE clause) and you'll get a subset.&lt;/p&gt;
&lt;p&gt;I also use it in comment blocks:&lt;/p&gt;
&lt;p&gt;-- Sample Execution:&lt;/p&gt;
&lt;p&gt;-- SELECT TOP 1000&lt;/p&gt;
&lt;p&gt;-- FROM HumanResources.Department&lt;/p&gt;
&lt;p&gt;--&lt;/p&gt;
&lt;p&gt;Use ALT to highlight just the query after the dashes and execute...&lt;/p&gt;
</description></item><item><title>re: Using Alt-select in SSMS, Word, and elsewhere</title><link>http://blog.sqlblog.com/blogs/john_paul_cook/archive/2012/09/08/using-alt-select-in-ssms-word-and-elsewhere.aspx#47499</link><pubDate>Tue, 05 Feb 2013 22:02:08 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:47499</guid><dc:creator>drsql</dc:creator><description>&lt;p&gt;When I learned about this around the time of my 2008 book, it saved me many many painful formatting casts to make text results look good by just hacking out whitespace like you have described.&lt;/p&gt;
&lt;p&gt;You can also paste in a column of text before or after code as well, which is where it becomes even more amazing. So if you have:&lt;/p&gt;
&lt;p&gt;a&lt;/p&gt;
&lt;p&gt;b&lt;/p&gt;
&lt;p&gt;c&lt;/p&gt;
&lt;p&gt;and&lt;/p&gt;
&lt;p&gt;1&lt;/p&gt;
&lt;p&gt;2&lt;/p&gt;
&lt;p&gt;3&lt;/p&gt;
&lt;p&gt;You can alt select and copy the 123, and then paste after the 1 and end up with&lt;/p&gt;
&lt;p&gt;a1&lt;/p&gt;
&lt;p&gt;b2&lt;/p&gt;
&lt;p&gt;c3&lt;/p&gt;
&lt;p&gt;Amazingly useful.&lt;/p&gt;
</description></item><item><title>re: Using Alt-select in SSMS, Word, and elsewhere</title><link>http://blog.sqlblog.com/blogs/john_paul_cook/archive/2012/09/08/using-alt-select-in-ssms-word-and-elsewhere.aspx#49489</link><pubDate>Fri, 07 Jun 2013 19:44:07 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:49489</guid><dc:creator>Valerie</dc:creator><description>&lt;p&gt;I have been using this for years, but it doesn't seem to work anymore - when I hold down the Alt key I get this annoying &amp;quot;Research&amp;quot; panel. Even if I mouse-down first and then hold the Alt key, it just selects horizontally. &amp;nbsp;Clues?&lt;/p&gt;
</description></item></channel></rss>