Presentation made in Sept. 2012 at the IGeLU Conference in Zurich, Switzerland.
Before the 2000's, PUCRS libraries generated different statistical on-demand reports by running several separate queries which consumed much time to be composed and executed, one at a time, through SQL clients.
To optimize this work, the library developed a method to run a batch of SQL queries during the night (simply using Linux shell scripts and native sqlplus) that feeds a large array of results in a MS-Excel file which contains different spreadsheets.
Each spreadsheet sums and gathers statistical data according to the information needs of University academic departments and government agencies. Thus, two statistical reports are monthly generated based on the information recorded in the Aleph database: (1) General Collection Data (687 SQL queries) and (2) General Circulation Data (106 SQL queries).
Both reports can generate: (a) numerical tables and also (b) charts (pie, line...). It is an economical and optimized solution which uses only Linux shell scripts, sqlplus and MS-Office Excel.
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Optimized creation of statistical reports for items and circulation transactions in Aleph500 (version 20)
1. Optimized creation of statistical
reports for items and circulation
transactions in Aleph500 (version 20)
Michelângelo Mazzardo Marques Viana
Pontifical Catholic University of Rio Grande do Sul
Porto Alegre - Rio Grande do Sul - Brazil
1
2. Main author of this development
Roberto Bertolo Moura
Senior System Librarian at PUCRS
2
8. The Pontifical Catholic University
of Rio Grande do Sul (1948)
PUCRS Main Campus is located in the capital city of Porto Alegre, Brazil. 8
Source: Google Maps
9. Research areas
Accounting Education Nutrition
Aeronautical Sciences Energy Pharmacy
Applied Social Sciences Engineering Philosophy
Architecture and Urbanism Environment Physical Education and
Bioethics Geriatrics and Gerontology Sports Science
Biomedical Research Human Sciences Physics
Biosciences Law Physioterapy
Brain Studies Letters Psychology
Chemistry Management Social Communication
Computer Science Mathematics Social Services
Dentistry Medicine Theology
Earth Sciences Natural Sciences Toxicology
Economics Nursing
9
10. Information needs
University’s
Brazil’s Ministry Library Higher
of Education Administration Administration
Collection Data
Circulation Data
Accesses Data
Analytical Data
10
11. Before: different flows
Information need SQL
Parameters Output Format Deliver
#1 queries
Information need SQL
Parameters Output Format Deliver
#2 queries
Information need SQL
Parameters Output Format Deliver
#3 queries
Information need SQL
Parameters Output Format Deliver
#n queries
11
12. Today: integrated flow for all reports
Specify all Initial and permanent settings.
information Modified only when there are changes.
needs
Define
global
parameters
Define which
primary data
to collect
Design the
Excel
Spreadsheets Group, Link
and
Combine
primary
data
Define SQL
statements On a desired frequency.
Schedule
SQL
automatic
execution Get collect
data and
paste them
into the
Spreadsheets
12
13. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Step by step execution…
13
14. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Specify all information needs
Collection
Circulation
Accesses
Simultaneous access
and so on
14
15. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define global parameters
Item status codes
Collections codes
User status codes
MARC contents for filter
Item material codes
What data must be grouped
15
16. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define which primary data to collect
About collection:
Number of current foreign printed periodicals
Number of licensed e-books of Human Sciences
Number of audiovisual documents added into the
collection in the last month
Number of books acquired by purchase for
Biological Sciences
16
17. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define which primary data to collect
About circulation:
Number of book loans made by each selfcheck-out
machine
Number of book returns made by each selfcheck-in
machine
Number of notebook loans by floor
Simultaneous use of notebook on each floor
Simultaneous use of study rooms on each floor
17
18. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define which primary data to collect
About accesses:
Access made by visitors
Access made by PUCRS users on study floor
Median of Number of daily accesses to the Library
Median of simultaneous users inside the Library at
same time by time range
Average number of hours that user stays in the Library
18
19. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Design the Excel Spreadsheets
19
20. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Design the Excel Spreadsheets
20
21. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Design the Excel Spreadsheets
21
22. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Design the Excel Spreadsheets
22
23. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Group, Link and Combine primary data
Group:
Join similar data in different TABs:
23
24. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Group, Link and Combine primary data
Link:
Associate each cells with its
respective cell of the MATRIX tab:
24
25. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Group, Link and Combine primary data
Link:
Associate each cells with its
respective cell of the MATRIX tab:
25
26. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Group, Link and Combine primary data
26
27. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Group, Link and Combine primary data
27
28. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Group, Link and Combine primary data
28
29. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Group, Link and Combine primary data
Combine:
Use SUM functions to calculate the totals:
29
30. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define SQL statements
SQL statements for collection:
687 queries
SQL statements for circulation and
accesses:
105 queries
30
31. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define SQL statements
31
32. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define SQL statements
32
33. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define SQL statements
33
34. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define SQL statements
34
35. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Define the schedule in JOB DAEMON
35
36. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Create a SHELL SCRIPT to execute the SQL
.SQL file location
36
37. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Store all queries inside a .SQL file
37
38. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Get collect data and
paste them into the Spreadsheets
Select * from
PUCRS.RESULTS
order by
DADO1, DADO2, DADO3
38
39. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Get collect data and
paste them into the Spreadsheets
39
40. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Get collect data and
paste them into the Spreadsheets
40
41. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Get collect data and
paste them into the Spreadsheets
41
42. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Get collect data and
paste them into the Spreadsheets
42
43. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Get collect data and
paste them into the Spreadsheets
43
44. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Get collect data and
paste them into the Spreadsheets
44
45. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Get collect data and
paste them into the Spreadsheets
45
46. Get collect data
Specify all Define which Design the Group, Link Schedule SQL
Define global Define SQL and paste them
information primary data to Excel and Combine automatic
parameters statements into the
needs collect Spreadsheets primary data execution
Spreadsheets
Get collect data and
paste them into the Spreadsheets
when the data is
collected and organized
in the spreadsheet, you
can create all graphics
needed.
46
47. Before and Today
Before
Different reports = different SQL queries
Too much work and too much time
Manual work
Today
Only one step to collect all data
Only one step to create all reports
Automated and fast work
47
48. Today: integrated flow for all reports
Specify all Initial and permanent settings.
information Modified only when there are changes.
needs
Define
global
parameters
Define which
primary data
to collect
Design the
Excel
Spreadsheets Group, Link
and
Combine
primary
data
Define SQL
statements On a desired frequency.
Schedule
SQL
automatic
execution Get collect
data and
paste them
into the
Spreadsheets
48