PhpMyLibrary Compared

http://www.geocities.com/marco_corvi/games/kernel/biblio/biblio.txt

biblio.txt

author marco corvi <marco_corvi@geocities.com>
date dec 2002
version 0.1

Disclaimer:
This information is provided only to help people to use these library
packages, as well as to help the developper to improve their product.
This is only my personal experience and impressions i got trying them
the first time. I have not done any extensive use of these packages,
nor i have ever used any other library package i can compare with.
My evaluation is incomplete. I do not claim the unfitness of any of
these package for any situation.

This page contains an analysis of four OpenSource projects for
the management of a library.

1. Koha
2. PhpMyLibrary
3. OpenBiblio
4. Briblioteca

All of them rely on a database (MySQL or PostGres) and provide a
web interface both for access to the library (search) and for
administration.

I have no knowledge of Cataloguing, therefore my evaluation is
limited to the computer information aspects only.

---------------------------------------------------------------
1. Koha 1.3.2 - http://www.koha.org/

Koha is a professional product.

The installation is helped by a PERL script and requires root privileges,
# ./installer.pl

The script creates the database "Koha" and its tables.
It also modifies the web server (Apache) configuration file
/etc/httpd/conf/httpd.conf creating a virtual hosting for Koha.
The olf configuration file is saved as httpd.conf.prekoha.
Finally it creates the file for the OPAC (Online Public Access Catalogue)
user interface, by default in /usr/local/koha/opac and for the administration,
in /usr/local/koha/intranet.

BIG WARNING: when the script asks which port to use for the Koha
virtual host, and suggests 80, enter a different number (say 81)
if you want to keep 80 for your web server.
The port for the administrator, 8080, is usually not used, so you
can leave it.

It is possible to set up a httpd-password protection on the administration
subdirectory. By default this in not done by the installation script.
In any case it is possible to do this later by modifying the Apache
configuration file.

The script asks for the MySQL root password.
This is used to create the database.
In case you do not have a MySQL root password, ie root can log on mysql
without entering the password (you should not do this, but it may happen
on your home PC), just enter carriage-return.

As i said the default database is "Koha", and the default database
administrator is kohaadmin. I decided to use the MySQL user "admin"
with password "admin". Infact if such user is already present
in the mysql table "user", the script reports an error at the INSERT
attempt.

The configuration file is /etc/koha.conf.
For easy management i made a sym link to it in /usr/local/koha.

The database is very structured and the number of table is large:
(abbreviations: n number
c code
d date/time
q quantity
acc account
amt amount
)
aqbookfund id, name, group
aqbooksellers id, name, address, ... ... ...
aqbudget id, start, end, budget
aqorderbreakdown nr, line_n, branch_c, bookfund_id, allocation
aqorderdelivery order_n, delivery_n, delivery_d, delivery_q, comment
aqorders order_n, biblio_n, title, ... ... ...
catalogueentry catalogueentry, entrytype, see, seealso, ... biblio_n
categories code, descr, enrolmentperiod, ...
categoryitem category_c, item_type, ... fine, firstremind, ...
classification classification
biblio nr, author, title, unititle, note, serial, series
copyrightdate, timestamp
deletedbiblio biblio_n, author, title, ... timestamp
biblioitems nr, biblio_n, volume, number, classification, itemtype,
isbn issn, dewey, subclass, pub_year, publisher_c,
volume_d, volumeddesc, timestamp, illus, pages, notes,
size, place
deletedbiblioitems biblioitem_n, biblio_n, volume, number, class, itemtype
isbn, issn, dewey, subclass, publ_year, publ_c, ...
biblioanalysis analyticaltitle, biblio_n, analyticalauthor
bibliosubject subject biblio_n;
bibliosubtitle subtitle, biblio_n;
additionalauthors author, biblio_n
publisher code, name
items nr, biblio_n, ... price, ... multivolume, stack, ...
deleteditems nr, biblio_n, multivolumepart, ... ... ...
newitems nr, publ_c, biblio_n, multivol_part, barcode, ...
itemsprices item_n, price1, price2
itemtypes type, descr, loanlength, renewalsallowed, rentalcharge
multipart item_n, other
multivolume biblio_n, multivolumepart
users usercode, username, password, level
userflags bit, flag, description, defaulton
issues borrower_n, item_n, branch_c, return_d, return, ...
borexp borrower_n, newexp
accountlines borrower_n, account_n, item_n, date, amount, ...
accountoffsets borrower_n, account_n, offset_acc, offset_amt, ..
borrowers nr, card_n, name, address, ... ... ...
deletedborrowers nr, card_n, name, ... ... ...
branchcategories category_c, branch_c, branchholding
branches code, name, address, phone, fax, email, issuing
branchtransfers item_n, sent_d, arrived_d, from, to, comments
currency currency, rate
printers name, queue, type
procedures code, descr, level
reserves borrower_n, reserve_d, biblio_n, ...
reserveconstraints borrower_n, reserve_d, biblio_n, biblioitem_n, timestamp
searchstats time, search
serialissues biblio_n, volume, nr, order_n, issue_d, received
statistics datetime, branch, proccode, value, type, other, ...
stopwords word
systempreferences variable, value

From a brief look at the tables one can see that Koha is a product
for a real-world complex library service, with branches, acquisition
orders, booksellers, etc.
There are two level of access: generic users (with only search capabilities)
and administrators. However the biblio entry informations is well structured.
For example a distinction is made among the entry "content" (biblio),
its "physical" aspect (biblioitem) and the actual holdings (items).
Of the four packages this is the only one that seems to take into account
these cataloguing criteria.

Koha requires several PERL modules, in particular the module
Net::Z3950 (with the "yaz' client, http://www.indexdata.dk/yaz/\)
if one wants to download bibliographical records from other
libraries. The Z39.50 is a standard for the retrieval of information
( http://lcweb.loc.gov/z3950/agency/ ).

Initially i had some problems due to mising PERL modules. I had to
install the following modules (all of them can be found on CPAN, the
comprehensive PERL archive network, http://www.cpan.org\) To see if
you have amodule installed, just type perl and ty to use the module:
> perl
use CGI;
...
In case the module is not installed perl will write an error message
and exits. When installing the modules follow the dependencies.
DBI
Date::Manip
DBD::mysql
Net::Z3950 (not neceessary)
HTML::Template
File::Spec
Cache::FileCache
IPC::ShareLite
Digest::SHA1
File::Spec
Storable
Error
CGI
POSIX
Digest::MD5
MARC::Record
Test::More <-- to do (this is in Test::Simple)
Test::Harness 2.03 <-- missing
MARC::File::USMARC <-- missing
Test::Harness
Locale::gettext
look for libintl, but can do without
Cdk
need libcdk (with devel)
Mail::Sendmail

Note: i had some problem with Cdk. Incompatibilities between
prototypes of functions/methods and their usage are easily fixed.
Use of undeclared variables is a bit tricky because one need to
declare them and initiallize to a sensible value too. I choose to
initialize to 0 or 1 whichever seemed appropriate to me ...

The PERL modules of Koha are in the subdirectory modules/C4. For example
C4::Database
C4::Output
C4::Auth
I had to insert these modules in the PERL include path.
In the koha installation directory there is the subdirectory
/usr/local/koha/intranet/modules with the "C4" modules.
I made /usr/lib/perl5/site_perl/5.6.0/C4 a sym link to it.
(I am using PERL 5.6, at the time of this writing the version is 5.8).

Koha makes an extensive usage of the Server Side Includes (SSI):
http://httpd.apache.org/docs/mod/mod_include.html
The file Hints contains some useful advices.

Overall I got the impression that Koha is very complete and is also fast
(especially when compared to PhpMyLibrary described next).
Probably the choice of PERL was motivated by easy of development,
performances, and modules availability at the same time.

Note.
I did not find the "sessions" and "sessionqueries" tables,
which are mentioned in some scripts.
However i have not received any error due to their lack.
It is also true that i did not experiment much.

-------------------------------------------------------------------
2. PhpMyLibrary 2.0.2 - http://phpmylibrary.sourceforge.net

A product for a small library

Although the README states it requires Apache 2.0.42, Mysql 3.23.39,
PHP 4.2.3 and phpMyAdmin 2.2.7 (this last one only if one does not want
to admin the database through 'mysql'), i managed to install and use it
on my rather outdated linux box (RedHat 7.1).

First of all one must create the database,
mysql> create database PhpMyLibrary;
and allow all grants on it to the "admin" user
mysql> grant all privileges on PhpMyLibrary.* to admin@localhost
> with grant option;

The connection data are stored in the file
polerio/config/conf.php.

The tables are created by the file polerio/sql/phpmylibrary.sql
which allows also to populate the database so that one can experiment
with it without having to enter many data manually.
The tables are rather complete,
_holdings id, barcode, holdingsid, location, accessno, type
_session_info sessid, ipaddr, firstused, lastused, uid, vars
_tbltitleindex id, title
_tblauthorindex id, author
_tblnotesindex id, note
_tblpublisherindex id, publisher
_tblsubjectindex id, subject
_tblbib id, marc, catid, approved, accessid
_tblanyindex id, any
_tblauthorbibrelation id, anyid, bibid
_tblnotesbibrelation id, anyid, bibid
_tblpublisherbibrelation id, anyid, bibid
_tblsubjectbibrelation id, anyid, bibid
_tbltitlebibrelation id, anyid, bibid
_tblanybibrelation id, anyid, bibid
_transaction id, holdingsid, userid, status, borrow, return
_users uid, gid, barcode, type, status, name, ...

There are the following objects:
- items (holdings)
- users
- loans (transactions)
- sessions
The informations of biblio holdings is structured in several tables
(title, author, subject, note, ...) and the connection is made through
relations,

--------- subject
/
holding ---------- author
\ --------- ...

To use PhpMyLibrary open the browser at

http://localhost/PhpMyLibrary

The interface is nice, and it is possible to configure different themes.
However the rendering is slow.
Apparently this is a problem of the browser, due to the complexity
of the pages created by the software, but i need to investigate more
to ascertain the cause.

There are four kinds of users:
- administrator
- librarian
- cataloger
- normal user
with decreasing levels of allowed actions.
In any case, even an unregistered user can do a search.

To admin do a login with username "admin" and password "admin"
(the password can be changed). As administrator one can see
which other users are present and their kind.
If you forget the password, you can always reset it with 'mysql'.

Inserting a biblio item is a work of "librarian".
It presents a list of tags and value fields, and you are supposed to
write the MARC tags and the corresponding content value.

-------------------------------------------------------------------
3. OpenBiblio - http://obiblio.sourceforge.net/index.php

A product for librarians.

The installation is very simple.
After untarring OpenBiblio in a subdirectory of the web document root,
say in "openbiblio", you must create the MySQL database,
mysql> create database openbiblio;

Next you can invoke the installation script through your browser,
following the instructions at
http://localhost/openbiblio/install_instructions.html

The configuration file with the database connection data is
openbiblio/database_constants.php.

The database contains the following tables:
biblio id, barcode, created, updated, material, collection,
title, subtitle, author, add_author, edition,
call_nr lccn_nr, isbn_nr, lc_call_nr, lc_item_nr,
udc_nr, udc_ed_nr,
publisher, pub_date, pub_loc, summary, pages,
physical_details, dimensions, accompanying, price
biblio_hold bibid, begin_date, mbrid
biblio_status bibid, begin_date, status, mbrid, renew_date, dueback_date
biblio_status_dm code, description, default_flag
collection_dm code, description, default_flag, days_dueback
material_type_dm code, description, default_flag,
adult_checkout_limit, juvenile_checkout_limit, image_file
mbr_classify_dm code, description, default_flag
member mbrid, name, ...
staff userid, username, ...
session userid, last_updated_dt, token
settings library_name, url, hours, phone, image, ...
state_dm code, description, default_flag
theme themeid, ... // presentation theme

Essentially there are four objects:
- biblio items
- loans
- users (members)
- staff
One weak point is the unstructured form of the items hold by the
library. A consequence is the replication of informtion (author,
publisher, ...) inside a table.

The status_dm contains the item status descriptions:
checked_in, checked_out, damaged/mending, display_area, hold_call,
hold_wait, lost, on_loan, on_order, shelving_cart.

The users (members) are distinguished in "adult" and "juvenile".

The codes of the material are:
audio_tapes, book, cd_audio, equipment, magazines, maps, video/dvd.

The codes of the collections are:
Adult Fiction, Adult NonFiction, Cassettes, Compact Discs,
Computer Software, Easy Readers, Juvenile Fiction, Juvenile NonFiction,
New Books, Periodics, Reference, Videos and DVDs.

These categories can all be modified, increased, or reduced through the
administration graphical interface (or directly with "mysql").
The presentation changes accordingly.

The service is accessed via web at
http://localhost/openbiblio

It seems however a library software providing a web interface for
librarians only. They can manage the library users, the loans, and so
on. Therefore it is a system for the automatic management of a library.
As such it may be sufficient for a home environment.
It is clearly designed for the USA (for instance the list of states
contains the only USA states) and for a middle size school library.

To login enter the username "admin" with password "admin".
To change the password you need to use 'mysql' and modify the
relevant field of the "staff" table,
mysql> update staff set pwd=password("...") where ...;

There are three folders
- Admin, for the database tables
- Cataloging, to search and insert new items (books)
- Circulating, to manage users and borrows

I tried to do some management.
Modifying the collections and adding new ones is very easy.
Same for staff members.
A nice feature is the choice of the presentation theme, and the
customisation of the library settings (name, hours, and so on).
Inserting biblio items was straightforward, and they reappear at the
proper search.

-------------------------------------------------------------------
4. Briblioteca 1.0.0 - http://web.tiscalinet.it/yurix

A simple product

It is a very simple software, and its major advantages are the easy
of installation and use. To install it you must create the database
"briblioteca" on mysql. Next you create the tables with the command
cat ... | mysql briblioteca

The database connectoin data are stored in the file
briblioteca/impostazioni.php. This must be edited with the suitable
username and password. I used "admin"/"admin" as for the other
products.

The tables are
log per i prestiti di libri conclusi con restituzione
altrolog per prestiti vari conclusi con restituzione
interprestito per i prestiti attivi
libro id, titolo, autore, editore, anno, collocazione, altro
raffina (lo stesso)
raffina2
prestiti utente, libro, data
utente id, nome, cognome, natoa, il, via, paese, cap, tel, email, ...

Thus the following obejcts are treated:
- loans (prestiti)
- items (libro)
- users (utente)
- history (log, altrolog)

To access the library you mustcopy the subdirectory "www" in a suitable
subdirectory of your web root directory, for example i copied it in
"briblioteca". Then open your browser at

http://localhost/briblioteca

To administer go to
http://localhost/briblioteca/admin
These pages should be protected with a http-password at least.
You have to do that by yourself modifying the web server configuration
file.

The great advantage of briblioteca is its easyness, and therefore the
quick adaptability and extension to particular needs. There is also
a "HACKING" file describing the structure of the package.

When trying to insert a new book i got a PHP error:
Warning: Supplied argument is not a valid MySQL result resource
==> NEED TO INVESTIGATE
this is generic for all queries:
/home/httpd/html/briblioteca/admin/mysql.php on line 22

Posted by Charles Fiddler 2004-06-04

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks