O'Reilly logo

RavenDB 2.x Beginner's Guide by Khaled Tannir

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Time for action – implementing the Search view

To implement the Search view, you will create an index that enables searching on the Name field. Then you will create the SearchingCitiesController class and its dedicated View. To display the search results, you will reuse the PartialCities view created in the previous section.

  1. Open the World application, right-click on the Indexes folder, add a new class, and name it Cities_SearchByName.
  2. Modify the Cities_SearchByName class as follows:
    Time for action – implementing the Search view
  3. Create a new Controller class, select the Empty MVC Controller template, and name it SearchingCitiesController.
  4. Make the SearchingCitiesController class inherit from

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required