Main -> Documentation -> Database Builder – Pears  -> Advanced Pears Database Options

Advanced Pears Database Options

You can perform several activities in SSDOT for Pears that fall outside the typical everyday administrative tasks associated with updating and maintaining a Pears database. Three of these advanced options enable you to examine and manipulate data without altering the structure or content of the database. Another option allows you to identify when a database was last updated. Yet another gives you a way to replay journals against a database in order to gracefully recover it. The action tables below contain the procedures for performing each of these advanced database activities in SSDOT for Pears.

Contents

Recommit Journal
Convert Input Data to BER-Formatted Records
View BER Conversion Log
Export Records to Their Native Format
Show Time of Last Database Update


Recommit Journal

During an update to a Pears database, SSDOT for Pears automatically produces a temporary journal file. So if something unexpected happens during the critical commit phase of the update process resulting in a corrupted database, the temporary journal may be played back against the most recent backup copy of the Pears database to recover it. An example would be a system or power failure during the critical commission of records. The table below contains the simple steps for performing a journal recommit to a Pears database.

1. Start SSDOT for Pears.

Result:

The following Main Menu appears:

Main Menu

1. Database Registration
2. BER Records
3. Database Creation and Maintenance
4. Database Backup
5. Advanced Options
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

2. Type 5 and press Enter to go to the Advanced Options menu.

Result:

The following menu appears:

Advanced Options

1. Recommit journal
2. Convert input data to BER formatted records
3. View BER conversion log
4. Export records in their native format
5. Show time of last database update
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

3. Type 1 and press Enter.

Result:

The following prompt appears:

Name of database to RECOMMIT or press [ENTER] key to return to menu:

4. Type the name of the database to which you want to recommit the journal and press Enter.

Result:

Information and a prompt similar to the following should appear:

Database journal successfully committed on database: marcus.

Press [ENTER] key to continue:

5. Press Enter to return to the Advanced Options menu.

Warning: If an SSDOT update fails due to an "out of memory error," you must not recommit the journal files to recover the database. An out of memory error corrupts the journals and renders them useless. Instead, your recovery procedure will consist of simply reinstating the most recent backup copy of the database.

Return to Contents


Convert Input Data to BER-Formatted Records

In order to identify the tag paths to specific fields within your records, you may want to convert all or a portion of them to BER before you actually load them into the database. Converting them ahead of time allows you to examine them for the purpose of deciding which indexes you want to create for the database. You need tag paths to create index definitions within the database description configuration file for a Pears database. Follow the steps below to convert your input data to BER records.

1. Start SSDOT for Pears.

Result:

The following Main Menu appears:

Main Menu

1. Database Registration
2. BER Records
3. Database Creation and Maintenance
4. Database Backup
5. Advanced Options
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

2. Type 5 and press Enter to go to the Advanced Options menu.

Result:

The following menu appears:

Advanced Options

1. Recommit journal
2. Convert input data to BER formatted records
3. View BER conversion log
4. Export records in their native format
5. Show time of last database update
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

3. Type 2 and press Enter.

Result:

The following prompt appears:

Name of input file to CONVERT or press [ENTER] key to return to menu:

4. Type the full directory path to the input file and press Enter.

Example:

 

Name of input file to CONVERT or press [ENTER] key to return to menu: <WebZ_root>/dbbuilder/dbs/marcus/marcus.dat

Result:

The following prompt appears:

Input record format or press [ENTER] to return to menu (e.g. "USMARC"):

 

5. Type the appropriate format type and press Enter.

Example:

 

Input record format or press [ENTER] to return to menu (e.g. "USMARC"): USMARC

Result:

The following prompt appears:

Output file name or press [ENTER] key to return to menu:

 

6. Type a directory path that includes the name of an output file and press Enter.

Example:

 

Output file name or press [ENTER] key to return to menu: <WebZ_root>/dbbuilder/dbs/marcus/marcus.ber

Result:

The following prompt appears:

Database description file to use or press [ENTER] key to return to menu:

7. Type the directory path to the database description configuration file and press Enter.

Example:

 

Database description file to use or press [ENTER] to return to menu: <WebZ_root>/dbbuilder/dbs/marcus/marcusdesc.ini

Result:

Information similar to the following appears:

Input file successfully converted to: <WebZ_root>/dbbuilder/dbs/marcus/marcus.ber.

Press [ENTER] key to continue:

Notes:

By default, input data records directly converted to BER are not in a human readable format. In order to display the records and read them after you have converted them to BER, you can run the ber2txt utility from your system prompt to convert them to a simple text format or you can convert and display them online using the display option in SSDOT for Pears. The difference between these two viewing options is that one is performed outside of SSDOT for Pears and the other is performed inside SSDOT for Pears.

An example of a ber2txt conversion might be: ber2txt -imarcus.ber>marcus.txt

You must execute the ber2txt utility from your system prompt within the directory where the utility resides.

 

8. Press Enter to return to the Advanced Options menu.

Return to Contents


View BER Conversion Log

If you want to review statistics on the last BER conversion that you performed, you can access this information off the Advanced Options menu in SSDOT for Pears.

1. Start SSDOT for Pears.

Result:

The following Main Menu appears:

Main Menu

1. Database Registration
2. BER Records
3. Database Creation and Maintenance
4. Database Backup
5. Advanced Options
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

2. Type 5 and press Enter to go to the Advanced Options menu.

Result:

The following menu appears:

Advanced Options

1. Recommit journal
2. Convert input data to BER formatted records
3. View BER conversion log
4. Export records in their native format
5. Show time of last database update
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

3. Type 3 and press Enter to view statistics on the last BER conversion that you performed.

Result:

Information similar to the following appears:

Wednesday, October 24, 2001 11:35:46 AM EDT <WebZ_root>/dbbuilder/dbs/marcus/marcus.dat conversion started by user
Wednesday, October 24, 2001 11:36:03 AM EDT
<WebZ_root>/dbbuilder/dbs/marcus/marcus.dat conversion ended by user
45 BER records created in 17.366 seconds.
Wednesday, October 24, 2001 11:36:03 AM EDT
####################################################
# Record Handler Report #
####################################################

RecordHandler Class Name . . . . . . . . . . . . . . ORG.oclc.RecordHandler.HandleUSMARC

--------------------------------------------------------
Number of Bytes Read . . . . . . . . . . . . . . . . 12,694,522 Bytes
Number of Garbage Bytes . . . . . . . . . . . . . . 0 Bytes
Number of Records Converted . . . . . . . . . . . . 45

Press [ENTER] key to continue or type "q" to quit:

4. Press Enter to return to the Advanced Options menu.

Return to Contents


Export Records to Their Native Format

All records in a Pears database are stored in BER format so that they can be searched and displayed in SiteSearch. To manipulate them outside of SiteSearch and in their original environment, you must first export them to their native format. The procedure below instructs you on how to do this to records in an existing Pears database.

1. Start SSDOT for Pears.

Result:

The following Main Menu appears:

Main Menu

1. Database Registration
2. BER Records
3. Database Creation and Maintenance
4. Database Backup
5. Advanced Options
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

2. Type 5 and press Enter to go to the Advanced Options menu.

Result:

The following menu appears:

Advanced Options

1. Recommit journal
2. Convert input data to BER formatted records
3. View BER conversion log
4. Export records in their native format
5. Show time of last database update
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

3. Type 4 and press Enter.

Result:

The following prompt appears:

Database name from which to EXPORT or press [ENTER] key to return to menu:

4. Type the name of the database and press Enter.

Result:

The following prompt appears:

Number of records to EXPORT or press [ENTER] key for all:

5. Type the number of records that you wish to export or press Enter to export all of them.

Result:

The following prompt appears:

Number of records to SKIP or press [ENTER] key for none:

 

6. Type the number of records that you wish to skip during the export or press Enter to skip no records.

Result:

The following prompt appears:

Output file name or press [ENTER] key to return to menu:

7. Type the path name to the file that will hold the exported records and press Enter.

Result:

Information similar to the following should appear:

####################################################
# Record Handler Report #
####################################################

RecordHandler Class Name . . . . . . . . . . . . . . ORG.oclc.RecordHandler.HandleUSMARC

--------------------------------------------------------
Number of Records Made . . . . . . . . . . . . . . . 44
Number of Records Read . . . . . . . . . . . . . . . 44
Number of Records Skipped . . . . . . . . . . . . . 0

Report generated by millertj

########### End Record Handler Report ##############


Data successfully exported to: <WebZ_root>/dbbuilder/dbs/marcus/marcus.marc

Press [ENTER] key to continue:

 

8. Press Enter to return to the Advanced Options menu.

Return to Contents


Show Time of Last Database Update

One way you can verify the currency of records that you are retrieving from a particular Pears database is to look at the time stamp associated with the last update to the database.

1. Start SSDOT for Pears.

Result:

The following Main Menu appears:

Main Menu

1. Database Registration
2. BER Records
3. Database Creation and Maintenance
4. Database Backup
5. Advanced Options
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

2. Type 5 and press Enter to go to the Advanced Options menu.

Result:

The following menu appears:

Advanced Options

1. Recommit journal
2. Convert input data to BER formatted records
3. View BER conversion log
4. Export records in their native format
5. Show time of last database update
6. Exit SSDOT

Working Database: No database selected

Type "l" To LIST available databases
Type "s" To SET a working database
Type "u" To UNSET the working database

Press [ENTER] key to return to Main Menu
>

3. Type 5 and press Enter.

Result:

The following prompt appears:

Name or database or press [ENTER] key to return to menu:

4. Type the name of the database and press Enter.

Result:

Information similar to the following should appear:

Tuesday, October 23, 2001 1:29:16 PM EDT

Press [ENTER] key to continue:

5. Press Enter to return to the Advanced Options menu.

 

Return to Contents



See Also

Pears System Overview
The SiteSearch Database Operations Tool (SSDOT) (For Newton)
Creating a New Pears Database
Pears Database Description Configuration File


[Main][Documentation][Support][Technical Reference][Community][Glossary][Search]

Last Modified: