28 Days of Sitecore Rocks: Hidden Gems - Part 2

Let's continue discussing a few more of Sitecore Rocks' hidden gems.  Today we will be covering searching Lucene indexes in the Query Analyzer, Search and Replace, and the Expanded web.config features of Sitecore Rocks.

Searching Lucene in Query Analyzer

One of the undocumented features in the Query Analyzer is the ability to search our Lucene indexes.  To search Lucene indexes simply add the "search" keyword after the "from" statement.  This will return results from which we can navigate to the corresponding item in Sitecore.


Sitecore Rocks


Search and Replace

Another hidden gem in Sitecore Rocks is the Search and Replace function.  The Search and Replace function gives us the ability to locate content in a Sitecore database and replace it with other content.


To open the Search and Replace screen, right click on a Sitecore database in the Sitecore Explorer and under "Tools" is the "Search and Replace" menu item.


Sitecore Rocks/Community/Technical Blogs/Trevor Campbell 2/srfeb2701


The Search and Replace dialog is pretty straightforward, simply enter the text that you want to find and the text to replace it with.  Optional parameters include which field, template and sub-items to search and replace on.


Sitecore Rocks


Behind the scenes the dialog is constructing a query for the Sitecore Rocks Query Analyzer to execute.


Sitecore Rocks


Expanded web.config

The Expanded web.config feature gives us the ability to see all the settings across each configuration file aggregated in a single location.  If you are familiar with the ShowConfig page in Sitecore then this is along the same lines.  It is a very helpful feature when you need to view all the configuration elements in relation to one another.


Sitecore Rocks


The Search Lucene in Query Analyzer, Find and Replace, and Expanded web.config are a few of the lesser known features of Sitecore Rocks but they still provide great value to developers.  These "hidden gems" will hopefully come in handy for you as they have for me!


Only one day left of the 28 Days of Sitecore Rocks, don’t miss out now!
  • I love having these fast query features right in the IDE, but I came across a problem where I wanted to use search to view a list of items where any field contained certain text. I believe the replace could do this, but I don't want to risk not being able to review the result before an actual update query.  In this case, there are not certain fields that can be searched by fast query because a batch pattern did not exist. I am thinking that a powershell script would give me more freedom without being too specific on a field level.