Re: MARC::Field::new_from_usmarc problems

2004-01-13 Thread Anne Highsmith
It shouldn't really be necessary to have different flavors of MARC for
this. Unlikes other leader positions, Base address of data is NOT
defined to be implementation-specific or implementation-defined. Bytes
12/16 are supposed to contain base address of data, and in this case,
simply appear to be incorrect.

Anne L. Highsmith
Consortia Systems Coordinator
5000 TAMU
Evans Library
Texas A&M University
College Station, TX   77843-5000
[EMAIL PROTECTED]
979-862-4234
979-845-6238 (fax)

>>> Ed Summers <[EMAIL PROTECTED]> 01/13/04 11:28AM >>>
On Tue, Jan 13, 2004 at 06:17:25PM +0100, Leif Andersson wrote:
> If it is in accordance with a special MARC flavour, then maybe
MARC::Record 
> should do something to meet this need? But, we do not know that yet.

Yeah, we could have new_from_xxx() for a different MARC flavors I
suppose. 

It might also be nice to be able to:

$MARC::RECORD::STRICT = undef;
$MARC::RECORD::WARNINGS = undef;

Which would have the same effects as:

$batch->strict_off();
$batch->warnings_off();

Which would allow for calls to new_from_usmarc() without bailing when
something
looks fishy...for advanced users only :)

But it would be even nicer to know exactly what's going on here first.

//Ed

-- 
Ed Summers
aim: inkdroid
web: http://www.inkdroid.org 

The deeper I go the darker it gets. [Peter Gabriel]




Re: MARC::Field::new_from_usmarc problems

2004-01-13 Thread Anne L. Highsmith
It shouldn't really be necessary to have different flavors of MARC for this. Unlikes 
other leader positions, Base address of data is NOT defined to be 
implementation-specific or implementation-defined. Bytes 12/16 are supposed to contain 
base address of data, and in this case, simply appear to be incorrect.

Anne L. Highsmith
Consortia Systems Coordinator
5000 TAMU
Evans Library
Texas A&M University
College Station, TX   77843-5000
[EMAIL PROTECTED]
979-862-4234
979-845-6238 (fax)

>>> Ed Summers <[EMAIL PROTECTED]> 01/13/04 11:28AM >>>
On Tue, Jan 13, 2004 at 06:17:25PM +0100, Leif Andersson wrote:
> If it is in accordance with a special MARC flavour, then maybe MARC::Record 
> should do something to meet this need? But, we do not know that yet.

Yeah, we could have new_from_xxx() for a different MARC flavors I suppose. 

It might also be nice to be able to:

$MARC::RECORD::STRICT = undef;
$MARC::RECORD::WARNINGS = undef;

Which would have the same effects as:

$batch->strict_off();
$batch->warnings_off();

Which would allow for calls to new_from_usmarc() without bailing when something
looks fishy...for advanced users only :)

But it would be even nicer to know exactly what's going on here first.

//Ed

-- 
Ed Summers
aim: inkdroid
web: http://www.inkdroid.org 

The deeper I go the darker it gets. [Peter Gabriel]




Re: MARC::Field::new_from_usmarc problems

2004-01-13 Thread Ed Summers
On Tue, Jan 13, 2004 at 06:17:25PM +0100, Leif Andersson wrote:
> If it is in accordance with a special MARC flavour, then maybe MARC::Record 
> should do something to meet this need? But, we do not know that yet.

Yeah, we could have new_from_xxx() for a different MARC flavors I suppose. 

It might also be nice to be able to:

$MARC::RECORD::STRICT = undef;
$MARC::RECORD::WARNINGS = undef;

Which would have the same effects as:

$batch->strict_off();
$batch->warnings_off();

Which would allow for calls to new_from_usmarc() without bailing when something
looks fishy...for advanced users only :)

But it would be even nicer to know exactly what's going on here first.

//Ed

-- 
Ed Summers
aim: inkdroid
web: http://www.inkdroid.org

The deeper I go the darker it gets. [Peter Gabriel]




Re: MARC::Field::new_from_usmarc problems

2004-01-13 Thread Leif Andersson

It appears to be deceptive values in leader pos 12-16, which is supposed to point to 
the beginning of data.
MARC::Record relies on this value.
I do not know, though, if this is a sign of a different MARC flavour, or if something 
bad has happened to the record.

If it is in accordance with a special MARC flavour, then maybe MARC::Record should do 
something to meet this need?
But, we do not know that yet.

Leif


Re: MARC::Field::new_from_usmarc problems

2004-01-13 Thread Ed Summers
On Tue, Jan 13, 2004 at 10:48:57AM +0200, Christoffer Landtman wrote:
> Any help on the matter is deeply appreciated as I really cannot make 
> anything of this, as it was working on my setup, but not on various 
> other peoples setups.

Could you send the program as an attachment to me Chistoffer? I'm not
confident that the MARC will have survived translation into the body of 
your email message.

Thanks! 
//Ed

-- 
Ed Summers
aim: inkdroid
web: http://www.inkdroid.org

The imagination of nature is far, far greater than the imagination of man.  [Richard 
Feynman]




MARC::Field::new_from_usmarc problems

2004-01-13 Thread Christoffer Landtman
Dear all,

I was wondering if there is anyone from the MARC::Record team on this 
list who possibly could give some insight in the following matter.

We are using MARC::Record to manipulate MARC records in Emilda [1] and 
we have been running into some unexpected problems. The actual 
manipulation code has not been altered lately, but people were reporting 
that MARC manipulation was behaving weird when testing Emilda. As such 
we had to look into the matter, and found out that there indeed was 
something weird going on, at least with some certain setups.

I managed to reproduce the error (I'm not quite sure if it is because of 
MARC::Record, but since it is MARC::Record that reports the error, I'm 
assuming it is) and added some debugging information to the code to see 
what is happening.

Here is a snipplet from the code, that displays the debugging information:



print "RAW: ".$self->{'MARC_blob'}."\n";
$record = MARC::Record::new_from_usmarc($self->{'MARC_blob'}) or die $!;
print "RES: ".$record->as_formatted()."\n";
print "WARN: ".join("\n", $record->warnings())."\n";


and what this outputs is:



RAW: 02599nam  2200025 a 
45040010011000300111005001700021008003900038020002300077035001500100035001900115035003300134047001670420012001740840021001860840018002071270022524500380025226000530029034100343599001000384653001600394653003200410653002000442653001600462653001900478653002000497841004800517841004800565841004800613841004800661841004800709841004700757841004900804841004700853841004900900841004700949841004700996841004801043841004901091841004701140841004901187841004901236841004801285841004701333841004901380852001101429852002501440852001701465852001301482852001301495852001701508852001101525852002901536852002201565852001101587852001701598852002801615852002601643852002401669852002501693852002101718852003801739852001101777852001801788976002301806000286ESBO_STAD20031030130634.0990309s1999 
   sw j  001 0 swe  a9129646103c183:00  99129646103 
 5Boa(Bo)368396  5Lahva(MMLahv)1999025970 
aNB  9NB9SEE  5SEEaUgg2kssb/6  aUgg,u2kssb/61 
aJansson, Hasse,d1949-00aTitta på fåglar! /cHasse Jansson 
aStockholm :bRabén & Sjögren,c1999 ;e(Danmark)  a61, [2] s. 
:bfärgill. ;c18 x 22 cm  aLi: S  5SbiaFåglar 
5LahvaFåglaraArtbestämning  5LaaFaktaböcker  5JonaFåglar 
 5LaaBarnböcker  5JonaBarnböcker  5Gpaxab0201080u0 
4000uu   |00e1  5Liaxab0201080u0   4000uu 
|00e1  5Laaxab0201080u0   4000uu   |00e1 
5Umaxab0201080u0   4000uu   |00e1  5Kdaxab0201080u0 
  4000uu   |00e1 
5Moaub030828|||001||00e1  5Jonaxab0201080u0 
  4000uu   |00e1  5Laxab0201080u0   4000uu 
|00e1  5Hsdaxab0201080u0   4000uu   |00e1 
5Oaxab0201080u0   4000uu   |00e1  5Qaxab0201080u0 
4000uu   |00e1  5Skaxab0201080u0   4000uu 
|00e1  5Sbiaxab0201080u0   4000uu   |00e1 
5Boaxb0201070u0   4000uu021001e1  5SEEaxab0201080u0 
  4000uu   |00e1  5Hlsaxab0201080u0   4000uu 
|00e1  5NBaxab0201080u0   4000uu   |00e1 
5Saxab0201080u0   4000uu   |00e1 
5Lahvaub030616|||001||00e1  5MobMo 
5LahvbLahvhUggxSus  5LabLahuUgg  5SEEbSEE 
5HsdbHsd  5GpbGphuUgg  5SkbSk 
5HlsbHlshUgg,ujJansson  5LibLicCNBhug,u  5UmbUm 
5KdbKdhUg,u  5JonbJonhUg BARNjJANS 
5LbLc0200h299/j102  5ObOhuUggjJansson 
5QbQclärahUg,u Jan  5SbShSv99j2878 
5NBbNBcNB99:12hgåvajKU, 990602  5BobBo  5SbibSbijRef 
2aUgg,ubFåglar Aves
RES: LDR 02599nam  2200025 a 4504
WARN: No directory found in record 1



"RAW" is the original MARC record to be manipulated and thus imported 
using new_from_usmarc(), but this seems to fail for some reason that is 
not apparent, at least to me.

Any help on the matter is deeply appreciated as I really cannot make 
anything of this, as it was working on my setup, but not on various 
other peoples setups.

Regards,

--
[1] http://emilda.org
--
Christoffer Landtman
Oy Realnode Ab
Partner, Sales
+358 (0)41 510 1073
[EMAIL PROTECTED]
www.realnode.fi