Quantcast

Delete selected records...

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Delete selected records...

Layale Bassil

Hello,

 

How can I delete some imported records from the VuFind index? I don’t want to clear all the index and re-index. I just want to delete a certain collection I imported along with its sub-items?

 

Thank you.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
VuFind-General mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-general
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Delete selected records...

Robert Haschart
If you can construct a query that matches all of the records that you want to delete, and none of the records you don't want to delete, it is easy.

create a file containing the following:

<delete><query>query that matches the records to delete</query></delete>

and then post that file to your Solr.   which can be done via curl, (somehow)  but I usually use the standalone java utility program  post.jar 

Alternately if you cannot create a query that matches all of the records you want to delete, without also matching some records you don't want to delete

you can create a file like the following listing each of the record ids you want to delete.

<delete>
<id>uva-lib:602113</id>
<id>uva-lib:617009</id>
<id>uva-lib:601005</id>
</delete>

and post that to your solr instance.

-Bob


On 5/15/2017 11:33 AM, Layale Bassil wrote:

Hello,

 

How can I delete some imported records from the VuFind index? I don’t want to clear all the index and re-index. I just want to delete a certain collection I imported along with its sub-items?

 

Thank you.



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot


_______________________________________________
VuFind-General mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-general


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
VuFind-General mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-general
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Delete selected records...

Demian Katz
In reply to this post by Layale Bassil

If you have the IDs of the records to delete, you can use the util/deletes.php script to delete a list of records found in a text file. If you need to use some other criteria, you can POST a query to Solr to delete a subset of records; see:

 

https://wiki.apache.org/solr/UpdateXmlMessages#A.22delete.22_documents_by_ID_and_by_Query

Let me know if you have any questions!

 

- Demian

 

From: Layale Bassil [mailto:[hidden email]]
Sent: Monday, May 15, 2017 11:34 AM
To: '[hidden email]'
Subject: [VuFind-General] Delete selected records...

 

Hello,

 

How can I delete some imported records from the VuFind index? I don’t want to clear all the index and re-index. I just want to delete a certain collection I imported along with its sub-items?

 

Thank you.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
VuFind-General mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-general
Loading...