You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by Sudheer Shinde <su...@gmail.com> on 2018/10/08 16:02:32 UTC

not able to use deleteDocByQuery: please provide detailed example

Solr version 6.2.1:

my schema:

id is primary key here:

 <field name="id" type="string" indexed="true" stored="true"
required="true" multiValued="false"/>
<field indexed="true" multiValued="false" docValues="true"
name="TC_0Y0_ItemRevision_0Y0_awp0Item_item_id" required="false"
stored="false" type="string"/>
<field indexed="true" multiValued="false" docValues="true"
name="TC_0Y0_Item_uid" required="false" stored="false" type="string"/>
<field indexed="true" multiValued="false" docValues="true"
name="TC_0Y0_ProductScope_0Y0_product_uid" required="false" stored="true"
type="string"/>



I want to delete using field TC_0Y0_ProductScope_0Y0_product_uid:

my db-data config file:
<entity name="onlydeleteByQuery" pk="pproduct"
transformer="TemplateTransformer"
query="Select pproduct from PQSEARCHINDEXEDPRODUCT t1 where t1.pis_deleted
= 1" >
<field column="${deleteDocByQuery}"
template="TC_0Y0_ProductScope_0Y0_product_uid:${onlydeleteByQuery.pproduct}"/>
<field column="ID" name="id" />
<field column="ITEMID" name="TC_0Y0_ItemRevision_0Y0_awp0Item_item_id" />
<field column="POBJECT" name="TC_0Y0_Item_uid" />
<field column="PEND_ITEM" name="TC_0Y0_ProductScope_0Y0_product_uid" />
</entity>

Re: not able to use deleteDocByQuery: please provide detailed example

Posted by Sudheer Shinde <su...@gmail.com>.
Thanks!
Sudheer

On Mon 8 Oct, 2018, 10:14 PM Steve Rowe, <sa...@gmail.com> wrote:

> Hi Sudheer,
>
> As Erick mentioned on SOLR-12841, you should post your question to the
> solr-user mailing list, rather than to this list (the Lucene/Solr
> development list).
>
> --
> Steve
> www.lucidworks.com
>
> > On Oct 8, 2018, at 12:02 PM, Sudheer Shinde <su...@gmail.com>
> wrote:
> >
> > Solr version 6.2.1:
> > my schema:
> > id is primary key here:
> >  <field name="id" type="string" indexed="true" stored="true"
> required="true" multiValued="false"/>
> > <field indexed="true" multiValued="false" docValues="true"
> name="TC_0Y0_ItemRevision_0Y0_awp0Item_item_id" required="false"
> stored="false" type="string"/>
> > <field indexed="true" multiValued="false" docValues="true"
> name="TC_0Y0_Item_uid" required="false" stored="false" type="string"/>
> > <field indexed="true" multiValued="false" docValues="true"
> name="TC_0Y0_ProductScope_0Y0_product_uid" required="false" stored="true"
> type="string"/>
> >
> > I want to delete using field TC_0Y0_ProductScope_0Y0_product_uid:
> > my db-data config file:
> > <entity name="onlydeleteByQuery" pk="pproduct"
> transformer="TemplateTransformer"
> > query="Select pproduct from PQSEARCHINDEXEDPRODUCT t1 where
> t1.pis_deleted = 1" >
> > <field column="${deleteDocByQuery}"
> template="TC_0Y0_ProductScope_0Y0_product_uid:${onlydeleteByQuery.pproduct}"/>
> > <field column="ID" name="id" />
> > <field column="ITEMID" name="TC_0Y0_ItemRevision_0Y0_awp0Item_item_id" />
> > <field column="POBJECT" name="TC_0Y0_Item_uid" />
> > <field column="PEND_ITEM" name="TC_0Y0_ProductScope_0Y0_product_uid" />
> > </entity>
>
>

Re: not able to use deleteDocByQuery: please provide detailed example

Posted by Steve Rowe <sa...@gmail.com>.
Hi Sudheer,

As Erick mentioned on SOLR-12841, you should post your question to the solr-user mailing list, rather than to this list (the Lucene/Solr development list).

--
Steve
www.lucidworks.com

> On Oct 8, 2018, at 12:02 PM, Sudheer Shinde <su...@gmail.com> wrote:
> 
> Solr version 6.2.1:
> my schema:
> id is primary key here:
>  <field name="id" type="string" indexed="true" stored="true" required="true" multiValued="false"/> 
> <field indexed="true" multiValued="false" docValues="true" name="TC_0Y0_ItemRevision_0Y0_awp0Item_item_id" required="false" stored="false" type="string"/>
> <field indexed="true" multiValued="false" docValues="true" name="TC_0Y0_Item_uid" required="false" stored="false" type="string"/>
> <field indexed="true" multiValued="false" docValues="true" name="TC_0Y0_ProductScope_0Y0_product_uid" required="false" stored="true" type="string"/>
>  
> I want to delete using field TC_0Y0_ProductScope_0Y0_product_uid:
> my db-data config file:
> <entity name="onlydeleteByQuery" pk="pproduct" transformer="TemplateTransformer"
> query="Select pproduct from PQSEARCHINDEXEDPRODUCT t1 where t1.pis_deleted = 1" >
> <field column="${deleteDocByQuery}" template="TC_0Y0_ProductScope_0Y0_product_uid:${onlydeleteByQuery.pproduct}"/>
> <field column="ID" name="id" />
> <field column="ITEMID" name="TC_0Y0_ItemRevision_0Y0_awp0Item_item_id" />
> <field column="POBJECT" name="TC_0Y0_Item_uid" />
> <field column="PEND_ITEM" name="TC_0Y0_ProductScope_0Y0_product_uid" />
> </entity>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org