Talk about the experience of converting Marc data - reading MARC data

xiaoxiao2021-03-06  51

Today, netizens on 9CBS will do the search for Marc data. It is not too low, and I asked me on blog. I am also afraid of everyone joke, write a MARC's reading article :)

The first thing to say, whether you read or write Marc data, you must eat the data format of Marc. If it is the format of CNMARC, it is strongly recommended to refer to the "Chinese Academic Directory Format Manual", which is very detailed in the format, guaranteed that he is half-power, and you don't have to look at me here.

Read, take 2 steps, one read, one take.

Read: The Marc file is the text of the .iso format, each record is branch, there is a conclude CHR (29). So you can read it in a row.

Take it: First obtain information on the record header area and address, then cut according to the location address of the address item. Here is a field separator CHR (30), subfield identifier CHR (31)

Still give a case:

$ -------- CHR (31)

@ -------- CHR (30)

% -------- CHR (29)

# -------- Space

The upper side is for the convenience of the convenience of artificial alternative symbols

This is a MARC data:

1. Head mark: 01071nam0 # 2200277 ### 450 #

Fixed 24 bits, pay attention to spaces. .

01071: Record total, 5

NAM0: If it is a book (with 225 fields), it is OAM2, of course, every one has a specific meaning. There are other changes. This is common.

22: Generally 22, the specific meaning can also be checked.

00277: The total length of the character before the data field area, 5 bits.

450: Generally, I have a book.

2. The address of the address, people have added ";" and ";"

001,0013,00000; 005,0017,00013; .....................................................................................................................

001,0013,00000: Represents field 001 (3 bits), character length 0013 (4 bits), position 00000 in the data field area 00000 (5)

801,0022,00771: Indicates field 801, character length 0022, starting in the data field area: 00771

Here is an important place to read, knowing these data, it is easy to divide. Each is a fixed length.

3. Data field area

012001022343@20020928000000.0 @ ## $ A7-80142-191-4 $ dcny46.00 @ ..................................................%%

The field is @ separated, the subfield is used.

@ ## $, here ## is the point of indicator. If the 101 field has an indicator 012, @ 012 $

Probably write these, the specific procedures have not been written, I don't know if there is no help, I hope it is a bit helpful.

A wind and one cloud

September 14, 2004

转载请注明原文地址:https://www.9cbs.com/read-116816.html

New Post(0)