OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



Error Indexing Archive

Open Harvester Systems support questions and answers, bug reports, and development issues.

Moderators: jmacgreg, michael, John

Forum rules
The Public Knowledge Project Support Forum is moving to http://forum.pkp.sfu.ca

This forum will be maintained permanently as an archived historical resource, but all new questions should be added to the new forum. Questions will no longer be monitored on this old forum after March 30, 2015.

Error Indexing Archive

Postby Grant » Wed Mar 16, 2005 8:10 am

Hi,

Whenever I try to index an archive, I get the following message :

Indexing Site ... done (0 new/updated records indexed)

I have applied the patch mentioned in another post :

Code: Select all
Index: include/harvester.inc.php
===================================================================
RCS file: /cvs/harvester/include/harvester.inc.php,v
retrieving revision 1.12
diff -u -r1.12 harvester.inc.php
--- a/include/harvester.inc.php 23 Feb 2004 00:50:03 -0000      1.12
+++ b/include/harvester.inc.php 8 Apr 2004 19:02:39 -0000
@@ -160,11 +160,11 @@
 
        if($protocol == 2) {
                // OAI 2.0
-               $dc_metadata = $record[metadata]['oai_dc:dc'];
-
-               if(!is_array($dc_metadata)) {
-                       $dc_metadata = $record[metadata]['oaidc:dc'];
-               }
+               $dc_metadata = isset($record[metadata]['oai_dc:dc'])
+                       ? $record[metadata]['oai_dc:dc']
+                       : (isset($record[metadata]['oaidc:dc'])
+                               ? $record[metadata]['oaidc:dc']
+                               : $record[metadata]['dc']);
 
                if(!is_array($dc_metadata)) {
                        return false;


But this does not seem to help. The archive is found as the correct e-mail, repository name, etc. is displayed on the "about page".

Do you have any idea of what could be the problem.

Thanks,
Grant
Grant
 

Postby Grant » Wed Mar 16, 2005 8:26 am

I have found that the code below is the problem :

Code: Select all
for($j=0; $j<count($oai_records); $j++) {
         
            // get metadata from record
            $metadata = formatMetadata($oai_records[$j], $protocol);
            
            // skip to next record if record is invalid
            if($metadata === false || empty($metadata[identifier]) || empty($metadata[title])) {
               continue;
            }


The continue statement is reached for all 10 records that I am trying to harvest.

Do you have any idea of why this would happen?

Thanks,
Grant
Grant
 

Postby Grant » Wed Mar 16, 2005 8:31 am

Hi,

Don't worry. Thanks. It seems to be working now.

Thanks,
Grant
Grant
 

Postby jbdj » Sat Sep 10, 2005 6:10 pm

Hi,

I have the same problem, what did you do to correct the problem?


JBDJ
jbdj
 
Posts: 16
Joined: Sat Feb 05, 2005 7:29 pm


Return to Open Harvester Systems Support and Development

Who is online

Users browsing this forum: No registered users and 0 guests