I have a script that fetches MARC records from my library's holdings via 
Z39.50.  Every once in a while a record doesn't have a MARC Record attached to 
it and I get the following error:

Can't call method "rawdata" on an undefined value at zrss.pl line 47, <STDIN> 
line 1.

Here's what I have on and around line 47:

        #create new record object
        my $rec = $rs->record($i);  
        
        #read in raw MARC to record
        my $mrec = MARC::Record->new_from_usmarc($rec->rawdata());

I would just like to skip those items without records or suppress this error 
and just go on to the next record, is this possible? 

Thanks.




Aaron S. Huber
Librarian I - Audiovisual/Popular Library
Northwest Regional Library
3151 University Drive
Coral Springs, FL 33065.
954-341-3965 ext 233
Broward County Library Division
A Service of the Broward County Board of Commissioners
[EMAIL PROTECTED]

>>> <[EMAIL PROTECTED]> 06/07/06 8:42 AM >>>

perl4lib Digest 7 Jun 2006 12:42:05 -0000 Issue 242

Topics (messages 2372 through 2372):

Module updates and HTML parsing question
        2372 by: Bryan Baldus

Administrivia:

To subscribe to the digest, e-mail:
        <[EMAIL PROTECTED]>

To unsubscribe from the digest, e-mail:
        <[EMAIL PROTECTED]>

To post to the list, e-mail:
        <perl4lib@perl.org>


----------------------------------------------------------------------


**********************************************************************
Please note: Except for state and federal exemptions, Florida has a very broad 
public records law. Most written communications to or from County employees 
regarding County business are public records and available to the public and 
media upon request. Your e-mail communications may be subject to public 
disclosure. 

This email and any files transmitted with it are intended solely for the use of 
the individual or entity to whom they are addressed. If you have received this 
email in error please notify the sender.

This footnote also confirms that this email message has been swept for the 
presence of computer viruses.
**********************************************************************

Reply via email to