﻿<?xml version="1.0" encoding="utf-8"?><rss version="2.0"><channel><title>Ayende @ Rahien</title><link>http://ayende.com</link><description>Ayende @ Rahien</description><copyright>Copyright (C) Ayende Rahien  2004 - 2021 (c) 2026</copyright><ttl>60</ttl><item><title>Ofer commented on Searching ain&amp;rsquo;t simple: solution</title><description>Two typo corrections:

1. Change "descried" to "described"
2. Change "archiect" to "architect" (in the balsamiq GIF)</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment15</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment15</guid><pubDate>Mon, 26 Mar 2012 07:00:00 GMT</pubDate></item><item><title>Vitaliy commented on Searching ain&amp;rsquo;t simple: solution</title><description>I may be missing the whole idea of the post, but what should be the solution if the label was "diagrams for architects"?</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment14</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment14</guid><pubDate>Sat, 24 Mar 2012 21:51:01 GMT</pubDate></item><item><title>Martin Doms commented on Searching ain&amp;rsquo;t simple: solution</title><description>Is that q.Suggest() method provided by RavenDB, or is that an extension method that the application developer would implement? Is it the "string distance algorithm" you mentioned?</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment13</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment13</guid><pubDate>Sat, 24 Mar 2012 21:05:02 GMT</pubDate></item><item><title>Paulo commented on Searching ain&amp;rsquo;t simple: solution</title><description>@Bill, thank you! I'll take a look at it!</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment12</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment12</guid><pubDate>Sat, 24 Mar 2012 18:08:21 GMT</pubDate></item><item><title>Bill commented on Searching ain&amp;rsquo;t simple: solution</title><description>@Paulo, that looks like Sublime Text 2 - http://www.sublimetext.com/2</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment11</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment11</guid><pubDate>Sat, 24 Mar 2012 17:22:22 GMT</pubDate></item><item><title>Paulo commented on Searching ain&amp;rsquo;t simple: solution</title><description>Sorry for the side question but... these screen caps aren't from Visual Studio IDE, are they?</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment10</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment10</guid><pubDate>Sat, 24 Mar 2012 13:33:43 GMT</pubDate></item><item><title>Phillip commented on Searching ain&amp;rsquo;t simple: solution</title><description>I don't like the name of the action when it can be searched by id as well as name... nit-picking tho.

I've written something similar for my project, this stuff took way too long to do with a relational database, it really is frictionless.</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment9</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment9</guid><pubDate>Fri, 23 Mar 2012 23:57:16 GMT</pubDate></item><item><title>Karep commented on Searching ain&amp;rsquo;t simple: solution</title><description>I'd refactor that code. I don't like the return at the end of ArchitectsByName. If there are result return immedately. Guard condition.</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment8</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment8</guid><pubDate>Fri, 23 Mar 2012 19:44:06 GMT</pubDate></item><item><title>Ayende Rahien commented on Searching ain&amp;rsquo;t simple: solution</title><description>Peter,
Yes, that is part of that.</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment7</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment7</guid><pubDate>Fri, 23 Mar 2012 15:03:18 GMT</pubDate></item><item><title>peter commented on Searching ain&amp;rsquo;t simple: solution</title><description>I see, you are using lucene SpellChecker.
Can I assume it is using statistics from the indexed ravendb documents to determine order of suggested terms?
</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment6</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment6</guid><pubDate>Fri, 23 Mar 2012 15:02:36 GMT</pubDate></item><item><title>Ayende Rahien commented on Searching ain&amp;rsquo;t simple: solution</title><description>Chris,
Results = new NameAndId[0]  -- Create a new empty array of NameAndId

The reason that we have two generic params is that it is NOT possible for us to infer the first parameter from the second, and yes, there are reasons why you would have different values there.</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment5</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment5</guid><pubDate>Fri, 23 Mar 2012 14:58:29 GMT</pubDate></item><item><title>Chris commented on Searching ain&amp;rsquo;t simple: solution</title><description>I think there is a typo in the code second code sample. I'm not sure what "Results = new NameAndId[0]" is.

Please forgive me if I am being dense, but why is it necessary to specify both the query type and the result type in Session.Query&lt;Architects_Search.Result, Architects_Search&gt;? It seems that Architects_Search.Result could be inferred since Architects_Search is declared to be AbstractIndexCreationTask&lt;Architect, Architects_Search.Result&gt;. Is it possible for Session.Query to be called as Session.Query&lt;Something_That_Is_Not_Architects_Search.Result, Architects_Search&gt;?</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment4</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment4</guid><pubDate>Fri, 23 Mar 2012 14:44:34 GMT</pubDate></item><item><title>Jason Meckley commented on Searching ain&amp;rsquo;t simple: solution</title><description>"And it turns out that when you think about it right, searching is simple."
A large portion of this is because RavenDB does all the heavy lifting for us. All we need to do is map the results from RavenDB to our view model.
Zero Friction FTW!</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment3</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment3</guid><pubDate>Fri, 23 Mar 2012 14:07:51 GMT</pubDate></item><item><title>Ayende Rahien commented on Searching ain&amp;rsquo;t simple: solution</title><description>Peter,
That is done inside RavenDB, yes.</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment2</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment2</guid><pubDate>Fri, 23 Mar 2012 14:00:53 GMT</pubDate></item><item><title>peter commented on Searching ain&amp;rsquo;t simple: solution</title><description>When you say "It does that by running a string distance algorithm" do you mean you already have this capability implemented in RavenDB?
Is it something like this one (what we ended up using inhouse):

https://github.com/lorenzo-stoakes/spell-correct

His implementation discussed here:
http://www.codegrunt.co.uk/2010/11/02/C-Sharp-Norvig-Spelling-Corrector.html

</description><link>http://ayende.com/153698/searching-ain-t-simple-solution#comment1</link><guid>http://ayende.com/153698/searching-ain-t-simple-solution#comment1</guid><pubDate>Fri, 23 Mar 2012 13:59:05 GMT</pubDate></item></channel></rss>