scary queries laid to rest getting started with voyager prepackaged access reports presented by jean...

36
SCARY QUERIES LAID TO REST SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of Texas at Dallas McDermott Library ELSUG October 2008

Upload: hector-bruce

Post on 23-Dec-2015

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

SCARY QUERIES LAID TO RESTSCARY QUERIES LAID TO REST

Getting Started with Voyager Prepackaged Access Reports

Presented by Jean Vik, Associate Library DirectorThe University of Texas at Dallas

McDermott LibraryELSUG October 2008

Page 2: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

OverviewOverview

PC Setup Microsoft Access Prepackaged Reports

Page 3: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Why MS AccessWhy MS Access

Create queries & reports using a graphical interface

Prepackaged reports installed with clients– C:\Voyager\Access Reports\Reports.mdb

Customize prepackaged reports & queries Design new reports & queries

Page 4: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Microsoft AccessMicrosoft Access

Must have Microsoft Access installed Install reports.mdb

– Administrator privileges on PC a must– Part of Voyager client installation– Instructions found in Voyager® 6.5 Reporter

User’s Guide (p. 1_17)– These reports are not run through Reporter

Page 5: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

PC SetupPC Setup Install and configure ODBC drivers

– Open Database Connectivity– Must match version of Oracle on server– Download from Ex Libris Support– Allows MS Access to communicate directly

with the Voyager database Uninstall old version of ODBC before

installing new one*

*See Voyager® Reporter User’s Guide for complete instructions.

Page 6: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Building Links to TablesBuilding Links to Tables Configure database links

– Go to C:\Voyager\Access Reports and click on the Reports.mdb file

– Access will open and reports: Database dialog box opens

a. Click the Forms button. b. Select Build database links to Voyager. c. Click the Open button.

Page 7: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Building Links to Tables in Building Links to Tables in Access 2003Access 2003

Access 2003 Forms Button

Page 8: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Building Links to Tables in Building Links to Tables in Access 2007Access 2007

Access 2007– Click down arrow

for menu– Choose Forms to

get to this view

Page 9: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Building Links to TablesBuilding Links to Tables

The first time the tables will fail to link

The word error! appears at the end of each table tried

Stops trying to link

Page 10: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Building Links to TablesBuilding Links to Tables

In earlier versions of Access choose

File>Get External Data> Link Tables

Page 11: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

ReLinking TablesReLinking Tables Office 2007

– Ribbon– Database Tools– Linked Table

Manager– Select tables to be

updated Copy Reports.mdb

file to other pc’s

Page 12: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

MS Access SecurityMS Access Security Set Security Level to

“Low” in 2003 Access 2007 has

added security Add path to your

Reports.mdb to the Trust Center to avoid this Security Alert

Click “Enable this content” to allow for one session

See “oracle9i_clientODBC.pdf for complete installation instructions.

Page 13: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Tables/Queries/ReportsTables/Queries/Reports

The down arrow on the left navigation pane allows switching between different categories:– Tables: show the linked Oracle tables– Queries: add specific criteria & build new

queries– Reports: built on top of a query to format data

for printing

Page 14: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Navigation PaneNavigation Pane

Page 15: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Access QueryAccess Query Right click a query and choose design view

to see the tables involved and how they are related

Page 16: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Query ResultQuery Result After running the query the results display in

tabular form Export to Excel to create a quick report

Page 17: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Data in ExcelData in Excel

Remove columns not needed in the report Sort

Page 18: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Access ReportAccess Report Running the report associated with this query

produces the same data nicely formatted for printing Cannot modify layout

Page 19: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Prepackaged Report HighlightsPrepackaged Report Highlights All prepackaged reports came from enhancement requests Limit results by adding Criteria

Page 20: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Prepackaged Query HighlightsPrepackaged Query Highlights

Acq: issues received by component and date range. This query uses a view table.

Page 21: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Creating Custom QueriesCreating Custom Queries First, make sure your report is not one of the

prepackaged reports! Decide which data elements should be included in

the report. Use the database dictionary to determine which

tables contain the required data. Create a new query in Access by adding these

tables. Other tables may be required for linking purposes.

Add the data elements from the tables and any criteria or restrictions.

Page 22: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Rules of ThumbRules of Thumb

Start small and save your queries frequently.

Make a copy of a query that has some of the elements you want & give it a new name.

First create the ‘core’ of your query, save it, then run it as a test.

Page 23: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Rules of Thumb Rules of Thumb

Looking at the prepackaged queries in design view is a good way to learn.

With practice, you will come to know the Voyager data structure and need to consult the printed tools less frequently.

Examine query results with a critical eye.

Page 24: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Example 1: Circulation asks for a Example 1: Circulation asks for a list of Community User Patronslist of Community User Patrons

What data elements should be included? Last name, first name, barcode, phone number

Is there a query that provides this information?

Check the Data Dictionary to determine which tables to use– Voyager® 6.5 Technical User’s Guide Appendix A

Page 25: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

List of Community User PatronsList of Community User Patrons

What data elements should be in the query? Last name, first name, barcode, phone number

Look at tables beginning with PATRON to find where this stuff lives.– The PATRON table contains the LAST_NAME &

FIRST_NAME.

– The PATRON_BARCODE table contains PATRON_BARCODE.

– The PATRON_PHONE table contains PHONE_NUMBER.

Page 26: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Community User PatronsCommunity User Patrons We also need to include PATRON_ADDRESS for

linking purposes and PATRON_GROUP so we can just limit to Community User.

Page 27: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Community User PatronsCommunity User Patrons To add data, simply double click the elements in

the tables.

Note: Criteria in Access are case sensitive.

Page 28: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Example 2: List Vendors Example 2: List Vendors Ordered from this FYOrdered from this FY

Data to include: Vendor name, order date Check the Data Dictionary to see which

tables to use– The VENDOR table contains VENDOR_NAME.– The PURCHASE_ORDER table contains

PO_CREATE_DATE.

Page 29: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

List of VendorsList of Vendors

Note: Enter criteria >9/1/2007 then Tab & Access adds correct formatting.

Page 30: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

List of VendorsList of Vendors Get a count of orders placed with vendors

between a range of dates specified at the time the query is run & sort the vendor names alphabetically.

The Totals function (the ∑ button) allows the use of aggregate functions like “count”

Use the Sort dropdown to alphabetize by Vendor name

Page 31: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Count of Orders by VendorCount of Orders by Vendor

Page 32: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Example 3: Shelf List by LocationExample 3: Shelf List by Location

Data to include: call number, title, enumeration/chronology, barcode.

Sort by call # and then enumeration. Tables used for bibliographic queries:

BIB_TEXT, BIB_MASTER, BIB_MFHD, MFHD_MASTER, MFHD_ITEM, ITEM, LOCATION, ITEM_BARCODE

Page 33: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

How are these tables related?How are these tables related?

Note: There are two intermediate tables for linking purposes: BIB_ MFHD and MFHD_ITEM. MFHD_ITEM can also be used to extract enumeration and chronology.

Page 34: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Shelf List by LocationShelf List by Location

Include both the NORMALIZED_CALL_NO field and the DISPLAY_CALL_NOField to get a correct sort of the Call Numbers

Page 35: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Voyager-L ReportsVoyager-L Reports

Email includes the SQL required for a report

Copy everything and paste it in a SQL view Change the view to Design View to see

which tables are used Modify criteria to match your local

locations, etc.

Page 36: SCARY QUERIES LAID TO REST Getting Started with Voyager Prepackaged Access Reports Presented by Jean Vik, Associate Library Director The University of

Questions?Questions?

Thank you and have a Happy Halloween!