EPrints Technical Mailing List Archive

Message: #00998


< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First

[EP-tech] Re: import "feature"


Well, congratulations anyway, Paolo!

You came up with the right solution   :)

Cheers,

	Jose.

-----Original Message-----
From: eprints-tech-bounces@ecs.soton.ac.uk [mailto:eprints-tech-bounces@ecs.soton.ac.uk] On Behalf Of Florian Heß
Sent: 31 August 2012 10:45
To: eprints-tech@ecs.soton.ac.uk
Subject: [EP-tech] Re: import "feature"

Am 30.08.2012 17:37, schrieb Paolo Tealdi:
> Dear all,
>
> as you know i'm testing 3.3.10.
> Our repository is a "read-only" repository : all records are imported 
> from another internal software used to collect publication records 
> from authors. The importing method is via batch file XML.
> When i implemented the past repository on 3.2.4 i noticed a strange 
> behaviour with import program, it seemed not to update records :
> --update parameter didn't work when the record was already present. I 
> resolved deleting and importing new records also per records already 
> present.
> Now with 3.3.10 version the situation seems to be similar: having more 
> experience with eprints source i debugged the import program again and 
> i think i'm resolving the problem with this little patch.
>

The patch below is official, cf. 
http://trac.eprints.org/eprints/changeset/7773.

Regards,
Florian

> --- /data/eprints-3.3.10/bin/import    2012-05-18 15:21:23.000000000 +0200
> +++ import    2012-08-30 17:28:07.000000000 +0200
> @@ -335,6 +335,7 @@
>                $item->update( $epdata,
>                        include_subdataobjs => 1,
>                    );
> +                        $item->commit();
>                print "EPRINTS_IMPORT: ITEM_UPDATED ".$item->get_id."\n"
> if $scripted;
>            }
>            elsif( defined($item = $opts{dataset}->create_dataobj( 
> $epdata
> )) )
>
>
> What do you think about ? Am i missed something ? Is it acceptable ?
>
> The import program is called with this parameters :
>
> ~/bin/import "EPRINTS_REPOSITORY"  --force --verbose 
> --enable-web-imports --enable-import-fields --update archive XML 
> "EPRINTS_XML"
>
> Best regards,
> Paolo Tealdi
>


--
UB Heidelberg (Altstadt)
Plöck 107-109, 69117 HD
- Informationstechnik
- WWW-Redaktion
Tel. 06221 / 54 3550
http://www.ub.uni-heidelberg.de/

*** Options: http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech
*** Archive: http://www.eprints.org/tech.php/
*** EPrints community wiki: http://wiki.eprints.org/