lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gora Mohanty <g...@mimirtech.com>
Subject Re: Variable datasources
Date Fri, 14 Jan 2011 05:09:37 GMT
On Fri, Jan 14, 2011 at 1:02 AM, tjpoe <tanner.postert@gmail.com> wrote:
[...]
> I also tried creating datasources for each local and then using a variable
> datasource in the entity such as:
>
> <datasource url="jdbc:mysql://localhost/aaa" name="content_aaa" />
> <datasource url="jdbc:mysql://localhost/bbb" name="content_bbb" />
> <datasource url="jdbc:mysql://localhost/ccc" name="content_ccc" />
> <datasource url="jdbc:mysql://localhost/master" name="master" />
>
> and then the document as:
>
> <document name="items">
>  <entity datasource="master" name="local" query="select code from locals"
> rootEntity="false">
>  <entity datasource="content_${local.code}" name="item" query=" select *,
> ${local.code} as code from item" />
>  </entity>
> </document>
>
> but the ${local.code} variable is not resolved and it attempts to connect to
> the literal source content_${local.code}.
[...]

As you have discovered, the datasource attribute is not variable resolved.
There was a thread on this subject a couple of days ago, and apparently
Alexei has resolved the issue. Please see:
http://www.mail-archive.com/solr-user@lucene.apache.org/msg45407.html

Regards,
Gora

Mime
View raw message