Skip to Content
author's profile photo Former Member
Former Member

Query-based taxonomy - DATE property

Hi,

have anybody tried to use query based taxonomy where queries are created on DATE-type property?

For example classifying documents into months, ...

Date properties does not show when defining the query.

Is it possible at all?

Roman

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Jun 23, 2004 at 04:22 PM

    Hi,

    I guess a search for a date attribute should be started.

    Therefore you have to specify:

    <b>queryEntry.setRowType(IQueryEntry.ROW_TYPE_ATTRIBUTE)</b>

    instead of

    queryEntry.setRowType(IQueryEntry.ROW_TYPE_TERM)

    Regards, Klaus

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      It is right.

      It works fine if I use Your suggestion and a String value in the search like this:

      queryEntry.setValue("20040629");

      But doen't work if I write:

      queryEntry.setPropertyType (IQueryEntry.PROPERTY_TYPE_DATE);

      Date d1 = new Date(y,m,g);

      queryEntry.setValue(d1);

      even if the property is a Date Type.

      Thanks. It's OK for me.

      Regards, Giorgio

  • author's profile photo Former Member
    Former Member
    Posted on Jun 03, 2004 at 02:00 PM

    Hi ,

    We've the same problem !!

    We cannot use CM date properties in Query Builder.

    Please help us ....

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      I have the same problem!

      I wrote some code to search documents using their properties.

      This piece of code works well if the property is a String type but

      doesn't work if the type of property is Date:

      IQueryEntry queryEntry = searchIndex.getNewQueryEntry();

      queryEntry.setRowType(IQueryEntry.ROW_TYPE_TERM);

      IPropertyName dataDocPropertyName = new PropertyName

      ("http://sapportals.com/xmlns/cm", "dataDoc");

      queryEntry.setPropertyName(dataDocPropertyName);

      queryEntry.setTermAction(IQueryEntry.TERM_ACTION_EXACT);

      queryEntry.setTermWeight(1.0F);

      Date d1 = new Date(y,m,g);

      queryEntry.setValue(d1);

      queryEntryList.add(queryEntry);

      Please help me.

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.