Thanks for your help, Erik. I got it working by forming $query with this: <xsl:variable name="query" select="concat($solr-url, 'select?q=%7B%21raw%20f=', name(), '%7D', encode-for-uri(normalize-space(.)))"/> I guess technically I could use url encoded double quotes, but my subject strings were not encoded, and therefore they will still throwing exceptions. Ethan On Fri, Jun 4, 2010 at 2:29 PM, Erik Hatcher <[log in to unmask]> wrote: > Use URL encoding. %22 is a double-quote url encoded. > > However... ! > > I strongly suggest using, for these "string" type fields where you want > _exact_ matching, the raw query parser. Like this: > > q={!raw f=subject}Egypt--Antiquities, Roman > > (of course URL encode the above too) > > The raw query parser under the covers creates a Lucene TermQuery, for an > exact match, and you avoid having to do all the query parser escaping > gymnastics for special parser syntax characters and such. > > Erik > > > > On Jun 4, 2010, at 2:15 PM, Ethan Gruber wrote: > > Does anyone on the list know off the top of their head if the query >> parameter (or some other parameter) can be altered in Solr to default to >> exact matching without double quotes. >> >> For example, I would like >> >> http://localhost:8080/solr/vocabularies/select?q=subject:Egypt--Antiquities,%20Romanto >> yield the same results as >> http://localhost:8080/solr/vocabularies/select?q=subject >> :"Egypt--Antiquities, >> Roman" >> >> I'm using the document function in XSLT to compare one set of elements >> with >> various results from Solr, but Saxon is spitting out a URIResolver: >> Invalid >> relative URI error. I have attributed the error directly to double quotes >> since the error doesn't trigger when my URL does not contain them. >> However, >> I get no matches without the double quotes since subject is a string >> field. >> >> Thanks, >> Ethan >> >