regexTransformer returns no results if there is no match

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

regexTransformer returns no results if there is no match

alxsss
Hello,

I try to construct wikipedia page url from page title using regexTransformer
with


<field column="title_underscore"  regex="\s+" replaceWith="_"  sourceColName="title" />

This does not work  for titles that have no space, so title_underscore for them is empty.

Any ideas what is wrong here?

This is with solr-4.8.1

Thanks. Alex.
Reply | Threaded
Open this post in threaded view
|

Re: regexTransformer returns no results if there is no match

Shalin Shekhar Mangar
You are right. I just tried this. It works correctly as long as you don't
use the same 'name' as the 'column' but it breaks if you use
'sourceColName'.

Can you please open a Jira issue?


On Tue, Aug 12, 2014 at 3:46 AM, <[hidden email]> wrote:

> Hello,
>
> I try to construct wikipedia page url from page title using
> regexTransformer
> with
>
>
> <field column="title_underscore"  regex="\s+" replaceWith="_"
> sourceColName="title" />
>
> This does not work  for titles that have no space, so title_underscore for
> them is empty.
>
> Any ideas what is wrong here?
>
> This is with solr-4.8.1
>
> Thanks. Alex.
>



--
Regards,
Shalin Shekhar Mangar.