what perl can do for you · •if you want, and you have everything you need for this, you can...
TRANSCRIPT
![Page 1: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/1.jpg)
What Perl can do for you
Phil Shirley
Cuyahoga Falls Library
![Page 2: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/2.jpg)
Goals
1. Learn about the process of running a Perl script
–So you can speak intelligently with an IT person who you want to do some Perl
–So you can try it yourself if you want
![Page 3: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/3.jpg)
Goals
2. Learn how libraries use Perl
–Understand how some scripts basically work
–Appreciate the more complex projects
–Grasp the scope of what Perl can do
![Page 4: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/4.jpg)
This presentation will not teach you anything about the Perl programming language or how to write, edit, or troubleshoot Perl scripts
![Page 5: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/5.jpg)
Overview
• What is Perl
• What you need
• Beyond the basics
• What libraries are doing with Perl
• Resources
![Page 6: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/6.jpg)
Dear computer,
Please take that file I just saved and give me a summary report.
kthxbye
![Page 7: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/7.jpg)
“Great, somebody posted a Perl script to do exactly what I need!
I wish I knew how to use it.”
![Page 8: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/8.jpg)
“We don’t have Perl.”
![Page 9: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/9.jpg)
What Perl Is
Perl is a general purpose programming language that’s especially good at manipulating text.
![Page 10: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/10.jpg)
Script? Program?
• Scripts and programs are changed (“compiled”) into commands the computer can understand.
• Scripts are compiled each time you run them.
• Programs are compiled once, when you finish writing them.
![Page 11: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/11.jpg)
Still, we use the word “programming” to refer to creating scripts.
![Page 12: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/12.jpg)
Some write it “PERL”
• “Practical Extraction and Report Language”
• Actually this is a backronym, just like “Gentlemen Only, Ladies Forbidden” (Golf).
![Page 13: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/13.jpg)
What do I need to get started?
– A computer
– A text editor
– A Perl script
– A Perl interpreter
– Perl modules (if needed by the script)
– Input
![Page 14: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/14.jpg)
Computer
– Your workstation (Windows, Mac, etc.)
– Just about any server (web, e-mail, Windows, etc.)
– Almost never your Innovative server
![Page 15: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/15.jpg)
Which computer you use depends on the particular task and/or what computers you have access to.
![Page 16: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/16.jpg)
Text editor
• For creating & editing Perl scripts
• A program for editing plain text files
– letters, numerals, symbols, tab, newline
– no fileformat-specific control characters for things like bold, italic, fonts, columns, tables
![Page 17: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/17.jpg)
Text Editors
–Not Microsoft Word, Wordpad, etc.
–Built-in:
• Notepad (Windows)
• SimpleText or TextEdit (Mac)
–Other specialized editors for programming exist
![Page 18: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/18.jpg)
Perl script
• A plain text file that you write (or copy from somebody else)
• Written in the Perl language
• Looks like this:
![Page 19: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/19.jpg)
#!c:\perl\bin\perl.exe
print "Hello World!";
![Page 20: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/20.jpg)
Perl interpreter
• A program you install on the computer where you’ll run scripts
• Changes the script into instructions the computer can understand
• Free!
![Page 21: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/21.jpg)
Perl Interpreter: Active Perl
http://www.activestate.com/Products/activeperl/index.mhtml
![Page 22: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/22.jpg)
Perl modules
• Extend the language
• Make it easier to do some kind of task
• Examples
– Net::FTP
– XML::Parser
– MARC::Record
![Page 23: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/23.jpg)
Input
• A text file that you want the script to do something with
• A script can also get some info from the computer (like date & time)
![Page 24: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/24.jpg)
Output
• A text file created by the Perl script
• Could be HTML, XML, MARC, RSS feed, etc.
• Or, could be just something normal for you to look at, print, paste into a report, etc.
![Page 25: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/25.jpg)
In summary, the components
– A computer
– A text editor
– A Perl script
– A Perl interpreter
– Perl modules if needed by the script
– Input
– [Output – created by the Perl script]
![Page 26: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/26.jpg)
• Questions so far?
![Page 27: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/27.jpg)
Beyond the Basics
• If you want, and you have everything you need for this, you can automate the running of scripts.
• Some libraries automate the running of Create Lists, process the output with a Perl script, and output an HTML file directly on their web servers.
• Of course, you can create and post a web page without doing it this way.
![Page 28: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/28.jpg)
Beyond the basics:Expect
An Expect script logs into the character-based system, runs Create Lists, and produces the input for a Perl script.
![Page 29: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/29.jpg)
Actually, Expect scripts can do just about anything in the character-based system.
![Page 30: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/30.jpg)
Beyond the basics:Scheduling an Expect script
• UNIX: cron
• Windows: Scheduled Tasks
![Page 31: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/31.jpg)
Beyond the basics:E-mail pipe method
– UNIX mail servers only (probably)
– Receives e-mail and uses /etc/aliases file to “pipe” the e-mail to a Perl script on that server
![Page 32: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/32.jpg)
Beyond the basics: Output
– Save the output file to the live directory on a web server or intranet server.
– It’s easier if your mail and web are on the same server.
![Page 33: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/33.jpg)
Beyond the basics,putting it all together:
Scheduling + Expect + email pipe method + web server
![Page 34: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/34.jpg)
Other advanced uses
• Using a Perl script to:
– Construct a database
– Query a database
– Interact with another script
– Communicate with another computer
![Page 35: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/35.jpg)
What Libraries Are Doing with Perl
• Create Lists
• Prepare Bib & Patron Data for Loading
• OPAC functionality• Circulation
• System administration
![Page 36: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/36.jpg)
Create Lists: How Perl Can Help
• Reformat the output of Create Lists to:
– Create a web page.
– Create an RSS feed.
– Etc.
![Page 37: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/37.jpg)
Create Lists: How Perl Can Help
• Bring out data that Create Lists can't display.
• Further refine your Create Lists query.
• Save the data in a different database (like MySQL).
![Page 38: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/38.jpg)
Simple Examples of Using Perl with Create Lists for the Public
![Page 39: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/39.jpg)
Creates a web page that’s a list of circulating videos from Create Lists output
http://library.mills.edu/screens/videocirc.html
Mills College
Script available from Alma Garcia ([email protected])
![Page 40: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/40.jpg)
![Page 41: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/41.jpg)
Creates a web page that’s a list of journals based on output from Create Lists
http://www.scripps.edu/library/open/all.html
The Scripps Research Institute
![Page 42: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/42.jpg)
![Page 43: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/43.jpg)
Creates an A-Z list of periodicals
http://library.truman.edu/search_articles/
electronic-journals.htm
Stephen Wynn
Truman State University
Script available from [email protected]
![Page 44: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/44.jpg)
![Page 45: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/45.jpg)
Generates new items RSS feeds from create lists output.
http://library.bury.gov.uk/screens/new_items_feeds.html
Alan Brown
Bury Libraries
Script available at http://www.innovativeusers.org/
cgi-bin/clearinghouse/view.pl?id=166
![Page 46: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/46.jpg)
![Page 47: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/47.jpg)
Creates web pages and RSS feeds of recent acquisitions grouped by broad subject area, department/program, and call number
http://library.lafayette.edu/collections/newacq
Bob Duncan
Lafayette College
Script available from [email protected]
![Page 48: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/48.jpg)
![Page 49: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/49.jpg)
![Page 50: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/50.jpg)
More Complex Examples of Using Perl with Create Lists for the Public
![Page 51: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/51.jpg)
Creates a web page and RSS feeds of new items which can be narrowed by subject area, media, library, time (today, last month, last 6 months), and sorted by title, call number, or author
Uses Perl, MySQL, and Perl/Expect
http://trilogy.brynmawr.edu/cgi-bin/
newbooks/newbook.pl
Tri-Colleges (Bryn Mawr, Haverford, Swarthmore)
![Page 52: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/52.jpg)
![Page 53: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/53.jpg)
![Page 54: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/54.jpg)
![Page 55: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/55.jpg)
Creates a title browse for videos and DVD's which can be limited by format and limited to new titles Uses Perl to populate a MySQL database, with a PHP front end
http://library.truman.edu/videos/TrumanVideos/
videosPHP.php
Stephen Wynn
Truman State University
Script available from [email protected]
![Page 56: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/56.jpg)
![Page 57: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/57.jpg)
Simple Examples of Using Perl with Create Lists for Staff
![Page 58: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/58.jpg)
Creates a shelf list, delivered automatically to a printer, of items for which overdue notices are about to be sent so that Circulation staff can check the shelves before sending notices
Stephen Wynn
Truman State University
Script available from [email protected]
![Page 59: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/59.jpg)
Creates and sends e-mail notices to requestors, alerting them that materials they have ordered are available in the library
Stephen Wynn
Truman State University
Script available from [email protected]
![Page 60: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/60.jpg)
Finds items that are awaiting processing which have bib-level holds and notifies cataloging staff via email
Stephen Wynn
Truman State University
Script available from [email protected]
![Page 61: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/61.jpg)
Reads Create Lists output and creates files of OCLC numbers for batch update, which are then updated using an AutoIt script
Phil Youngholm
MARINet
![Page 62: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/62.jpg)
More Complex Examples of Using Perl with Create Lists for Staff
![Page 63: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/63.jpg)
Notifies selectors that their materials have arrived based on the selector field in order records
Uses Expect module for Perl
Tri-Colleges (Bryn Mawr, Haverford, Swarthmore)
![Page 64: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/64.jpg)
Creates a list of items on reserve, sorted by course title
Uses Create Lists and Patron API
John D. Boggs
Peninsula Library System
![Page 65: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/65.jpg)
Uses a monthly full MARC extract (using Data Exchange) and populates a rudimentary stock management tool; generates reports from this database such as top issuing authors, missing items, and worn stock
Uses Perl and MySQL
Alan Brown
Bury Libraries
![Page 66: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/66.jpg)
You Can’t Do that with Create Lists… but you can if you add Perl
![Page 67: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/67.jpg)
Finds and reports duplicate patrons
Stephen Wynn
Truman State University
Script available from [email protected]
![Page 68: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/68.jpg)
Identifies duplicate copies for weeding
John Wenzler
San Francisco State University Library
![Page 69: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/69.jpg)
Creates a web page of purchase alerts based on the holds per title ratio, based on output from Create Lists
http://odie.aadl.org/iug_clearinghouse/
pa_example.html
Glen Modell
Ann Arbor District Library
Script available at http://innovativeusers.org/
cgi-bin/clearinghouse/view.pl?id=189
![Page 70: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/70.jpg)
![Page 71: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/71.jpg)
![Page 72: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/72.jpg)
Prepare Bib & Patron Data for Loading
![Page 73: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/73.jpg)
Creates patron barcodes for incoming student data loads given a beginning barcode (without check digit)
Christopher King
Appalachian School Of Law
Script available at
http://www.asl.edu/library/hal/pbargen.pl
![Page 74: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/74.jpg)
Adds additional patron barcode field entries before loading patron records (the barcode without leading digits and the campus ID number)
Steve Sowder
Andrews University
Script available from [email protected]
![Page 75: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/75.jpg)
Creates MARC patron records from a delimited text file created from an Excel file received by the Admissions Office
Amy Moberly
California Western School of Law
Script available from [email protected]
![Page 76: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/76.jpg)
Extracts last four digits of phone number from Create lists output, inserts this as a PIN field, and creates a delimited file that can be turned into MARC format using MarcEdit
Phil Shirley
Cuyahoga Falls Library
Script available from
![Page 77: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/77.jpg)
Reorders the ISBN's in bib records, putting the 10 digit ISBN first in order to use Amazon book jackets
Alan Brown
Bury Libraries
![Page 78: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/78.jpg)
Rearranges data in MARC records for electronic resources to make them work with existing load tables – easier than creating new load tables (uses MARC module for Perl)
Michael Kreyche
Kent State University
![Page 79: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/79.jpg)
Creates a web-based system for retrieving, validating, reviewing, and manipulating MARC records, and documenting loads (uses Perl, the MARC module for Perl, and PHP)
Michael Kreyche
Kent State University
![Page 80: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/80.jpg)
Coverts a special collection from excel files to MARC
Ann Anderson
The Boeing Company
![Page 81: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/81.jpg)
Converts data into a format to feed in an enterprise search
Ann Anderson
The Boeing Company
![Page 82: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/82.jpg)
Cleans and separates data in MARC records for uploading to union catalogs and other services
Alan Brown
Bury Libraries
![Page 83: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/83.jpg)
OPAC Functionality
![Page 84: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/84.jpg)
Creates a catalog feature allowing patrons to navigate through Library of Congress call number outlines to class number level, where patrons can search by that class number, search the associated subject heading, find most popular titles in a class, and more.
http://bullpup.lib.unca.edu/scripts/lcclass/outline.htm
Mark Stoffan
Western North Carolina Library Network
![Page 85: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/85.jpg)
![Page 86: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/86.jpg)
![Page 87: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/87.jpg)
![Page 88: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/88.jpg)
![Page 89: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/89.jpg)
Creates a feature in the web OPAC which allows patrons to send SMS messages to their phones with title, shelving location and call number of any item (uses Javascript, HTML, and Perl).
http://tripod.brynmawr.edu/
Tri-Colleges (Bryn Mawr, Haverford, Swarthmore)
Script available at http://www.innovativeusers.org/cgi-bin/
clearinghouse/view.pl?id=187
![Page 90: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/90.jpg)
![Page 91: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/91.jpg)
![Page 92: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/92.jpg)
![Page 93: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/93.jpg)
Includes Syndetics and Google Books data in catalog records (using Perl and Javascript).
http://tripod.brynmawr.edu/
Tri-Colleges (Bryn Mawr, Haverford, Swarthmore)
![Page 94: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/94.jpg)
Circulation
![Page 95: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/95.jpg)
Updates ITYPEs for ILL materials that have not been checked out (as loan periods for ILL's are controlled through ITYPE at this library), and notifies ILL staff when such materials should be returned to the lending library
Stephen Wynn
Truman State University
Script available from [email protected]
![Page 96: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/96.jpg)
Posts Ariel document delivery to a web server
John Dillon
Saint Anselm College
![Page 97: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/97.jpg)
Takes the web server log, a list of items for electronic resources, and a list of courses, and produces usage stats for each resource by course
Mark Huppert
The Australian National University
Script available at
http://preview.tinyurl.com/68s6qm
![Page 98: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/98.jpg)
•Reformats paging slips and sends them to the appropriate groups for disposition.
•Reformats and sends notices via e-mail
Ann Anderson
The Boeing Company
![Page 99: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/99.jpg)
•Creates and sends out courtesy notices
•Sends e-mails to indicate that an item is in the mail for a patron (takes advantage of the Oracle back end)
Ann Anderson
The Boeing Company
![Page 100: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/100.jpg)
System Administration
![Page 101: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/101.jpg)
Logs into the character-based system to run reports and perform maintenance tasks (uses Expect module for Perl)
Tri-Colleges (Bryn Mawr, Haverford, Swarthmore)
![Page 102: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/102.jpg)
Works with EZproxy and Patron API to allow users to verify on either PIN or last name
John D. Boggs
Peninsula Library System
![Page 103: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/103.jpg)
Works with a proxy server for access to electronic resources
Steve Sowder
Andrews University
![Page 104: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/104.jpg)
Synchronizes EZProzy and URL's in the catalog by creating a list of new or modified 856 fields and transforming them to EZProxy format (uses Perl Expect module, PHP, and MySQL)
Tri-Colleges (Bryn Mawr, Haverford, Swarthmore)
![Page 105: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/105.jpg)
Examines CybraryN log files and calculates the number of users
Cuyahoga Falls Library
![Page 106: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/106.jpg)
Processes a web form and e-mails the results
Cuyahoga Falls Library
![Page 107: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/107.jpg)
Where to find more of other libraries' scripts
IUG Clearinghouse and listservhttp://www.innovativeusers.org/
![Page 108: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/108.jpg)
How to learn the Perl language
– Books such as:
• Learning Perl by Randal Schwartz, Tom Christiansen, Larry WallA good book for beginners
• Programming Perl Larry Wall, Tom Christiansen, Jon OrwantA great reference
• Win32 Perl Programming by Dave RothGood for automating Windows functions
![Page 109: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/109.jpg)
Another Resource
Perl4lib: Perl for Libraries listserv and web site
http://Perl4lib.Perl.org/
![Page 110: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/110.jpg)
Other tools
• MarcEdit
• Other scripting languages
![Page 111: What Perl can do for you · •If you want, and you have everything you need for this, you can automate the running of scripts. •Some libraries automate the running of Create Lists,](https://reader030.vdocuments.site/reader030/viewer/2022041014/5ec5c18d75eb2b22f126d79d/html5/thumbnails/111.jpg)
Questions?
pshirley@CuyahogaFalls Library.org