Hi Mike,

Many thanks. It won't take long to update the project's preprocessing files, 
transform, load. They were designed to use attributes for this data because I'm 
certain there will be no mixed content and contain only a few short word tokens 
belonging to a controlled vocabulary. I thought it would be fine to use an 
attribute range index for that purpose, I wasn't aware that a specific value 
was required until I found I wanted to include the values in a 
default-suggestion-source. I need more than one index to be the source, so a 
field is called for. I agree that it would be nice to make use of existing 
attribute range indexes, but it's probably not worth an RFE in this case--easy 
workaround, small dataset.

Thanks,
Shannon 

On Oct 24, 2012, at 11:20 AM, Michael Blakeley <m...@blakeley.com> wrote:

> Is the goal to set up a field that indexes attribute words? As far as I know 
> that isn't possible. Fields only seem to pick up word-query terms, whatever 
> the include-exclude settings. This makes more sense if you recall that 
> attribute words match cts:element-attribute-word-query(), but attribute words 
> don't match cts:word-query().
> 
> cts:contains(
>  <p>hello world</p>,
>  cts:word-query('hello')),
> cts:contains(
>  <p value="hello world"/>,
>  cts:word-query('hello')),
> cts:contains(
>  <p value="hello world"/>,
>  cts:element-attribute-word-query(
>    xs:QName('p'), xs:QName('value'), 'hello'))
> =>
> true
> false
> true
> 
> It would be nice to have the option to index attribute words in word-query 
> and fields, but for now I think you'd have to transform or duplicate the 
> attribute words as element words.
> 
> -- Mike
> 
> On 24 Oct 2012, at 07:18 , Shannon Scott Shiflett <shifl...@virginia.edu> 
> wrote:
> 
>> Hi,
>> 
>> Is it possible to include an attribute in a field index without specifying a 
>> value? Would you recommend preprocessing? 
>> 
>> Thanks.
>> _______________________________________________
>> General mailing list
>> General@developer.marklogic.com
>> http://developer.marklogic.com/mailman/listinfo/general
>> 
> 
> _______________________________________________
> General mailing list
> General@developer.marklogic.com
> http://developer.marklogic.com/mailman/listinfo/general

_______________________________________________
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to