SUPRTOOL Version 4.3 Database Handyman for HP-UX Change Notice Installation Instructions Addendum to 4.2 User Manual Suprtool 4.3 Suprlink 4.3 STExport 4.3 Robelle Consulting Ltd. Unit 201, 15399-102A Ave. Surrey, B.C. Canada V3R 7K1 Toll-free: 1-888-ROBELLE (1-888-762-3553) Phone: (604) 582-1700 Fax: (604) 582-1799 E-mail: support@robelle.com Web: www.robelle.com February 2000 Program and Manual Copyright Robelle Consulting Ltd. 1981-2001 Permission is granted to reprint this document (but not for profit), provided that copyright notice is given. QEDIT and SUPRTOOL are trademarks of Robelle Consulting Ltd. Other product and company names mentioned herein may be the trademarks of their respective owners. Introducing Suprtool/UX Version 4.3 ü Highlights ü Known Problems ü Compatibility ü CPU Serial Number (uname) ü Documentation ü Documentation in WinHelp Format Use Suprtool/UX to read, select, and sort data from Oracle and Allbase databases and from data files with fixed-length records. Suprtool/UX is designed to be similar to Suprtool for MPE while providing necessary HP-UX features. Suprlink/UX provides high-speed data-file linking based on a sort key. Use STExport to convert fields in a self-describing input file into an output file that can be imported into different applications. We appreciate you trying Suprtool/UX. Let us know how Suprtool/UX meets your HP-UX data needs. Highlights in Version 4.3 Data functions ü Compute the absolute value of an expression using the $ABS function. ü Compute the integer portion of an expression using the $TRUNCATE function. ü Patterns in the If command can be much larger. Date functions ü New date formats supported: new phdate format in integer fields for versions of PowerHouse 8.19 and higher, EDSDATE and Julian Day number. ü Convert any date to a Julian Day Number with the $DAYS function. System functions ü Suprlink and STExport are now capable of reading and writing files greater than 2 Gigabytes. ü Suprtool now allows the '$' character to be used in field names. ü Suprlink and STExport now support filenames up to 240 characters in length. ü Get the version number with Verify Version in Suprtool. Known Problems There are no known problems at this time. Compatibility Suprtool/UX is compatible with HP-UX 9.0, all versions of HP-UX 10.x, as well as Oracle version 7.1.3.2.0. On HP-UX 10.x, Suprtool/UX creates all of its temporary and scratch files in /var/tmp, unless you have overridden the temporary directory with the TMPDIR environment variable. Suprtool for HP-UX typically comes with two versions in two different directories on your tape. The version of Suprtool in /opt/robelle is compatible with HP-UX 10.20 and later. The version of Suprtool in /usr/robelle is compatible with versions earlier than HP-UX 10.20. CPU Serial Number (uname) This program runs only on CPUs whose serial numbers have been encoded (the "uname" on HP-UX). If it fails to run and you get an "invalid HPSUSAN" error message, call Robelle for assistance. Documentation The user manuals for Suprtool and its components are available on-line. You can access these files from within Suprtool by simply typing "help." We also distribute all three user manuals as a Windows Help file. If you are already familiar with Suprtool, you can access only the Suprtool/UX topics that are different from those of Suprtool/MPE. The "Running" section of the help file has been updated for Suprtool/UX. You can access it with this Help command: >help running Documentation in WinHelp Format The user manuals for Suprtool and its components are all available in the popular WinHelp file format of Microsoft Windows. Your tape includes a WinHelp file, which is a self-extracting compressed file that contains all five Help files and a Setup program. Use the installation instructions in this change notice to install the WinHelp files on your PC. Installation of 4.3 The following instructions describe the installation process of a new Suprtool release. The new version overwrites an existing version of Suprtool on your HP-UX system. Who Should Use These Instructions? The system manager should use the following instructions to install Suprtool/UX. During the installation, which should take only a few minutes, no one can use Suprtool/UX. Replace Any Pre-Release If you are currently running a pre-release version of Suprtool, you should replace it with this new official release. Pre-release versions expire within two years of their creation date, whereas this new release has no expiry date. You can easily recognize a pre-release by the words "Pre-Release" next to the version number. Summary of Installation Steps To install Suprtool, follow these steps: 1. Log in as root. 2. Create the correct directory structure. 3. Restore Suprtool/UX and its associated files from the distribution tape. 4. Set up variables to let Suprtool know where its supporting files are. 5. Install WinHelp documentation files. (optional) Installation Assistance If you have any questions or run into any problems, please call us. Technical support is available on weekdays from 7 a.m. to 4 p.m. Pacific time at 1-888-ROBELLE (1-888-762-3553). You can also receive emergency support outside of these hours by calling our regular phone number and asking the operator to page a support person for you. Step 1: Log In as Root There are two ways you can log in as root: a. Exit from HP-UX and log in with root as the user name. b. If you are already logged in, you can execute this command: su - In either case, you have to know and supply the user password for root. Step 2: Create Robelle Directory Before restoring files, you must first create the directory where Suprtool/UX will reside: mkdir /opt/robelle Step 3: Restore Files Use the following command to restore the Suprtool/UX files from the distribution tape: tar xv /opt/robelle This command assumes your tape device is /dev/rmt/0m. If it is not, you need to specify your tape device using the "f" option in the tar command. For example, if your tape device is /dev/rmt/1m, you need to use the following command to restore the files: tar xvf /dev/rmt/1m /opt/robelle Step 4: Set the ROBELLE Variable You must set the ROBELLE environment variable so that Suprtool can find its Help and Suprmgr files. Bourne and Korn Shells export ROBELLE=/opt/robelle C Shell setenv ROBELLE /opt/robelle Step 5: Install WinHelp Documentation Files (optional) The Suprtool documentation for both MPE and HP-UX is now available in the WinHelp format of Microsoft Windows. You can only use these files if you have Windows 3.1 or later. To install the WinHelp files on a PC, follow these instructions. Make a Temporary Directory for the Setup Program Create a directory for the installation file on your PC. You can remove this directory after installing the WinHelp files. At the DOS prompt, for example, type mkdir \robtemp Download the Compressed File If you use the floppy diskette that is included in the Suprtool User Manual to copy the Help files to your hard drive, proceed to "Run the Setup Program" below. Otherwise, use Reflection to download the self-extracting Zip file to your PC and continue with these steps. The file on the HP 9000 is /opt/robelle/winhelp/suprhelp.exe From the /opt/robelle/winhelp directory, press Alt-Y to go to the Reflection Command Line window. Then download the file as a binary transfer. receive c:\robtemp\suprhelp.exe from /opt/robelle/winhelp/suprhelp.exe binary Expand the Compressed Files You only need the following commands to extract the files because we provide both the Setup program and the Help files in one self-extracting Zip file. From the DOS prompt, type the following commands: cd \robtemp {go to the new Robtemp directory} suprhelp.exe {extract the Help files} Run the Setup Program From the Program Manager, run the Setup program by choosing the Run option from the File menu. Then enter c:\robtemp\setup in the Command Line window and follow the instructions in the Setup program. You can now access all of the Suprtool documentation by selecting any of the icons in the "Robelle Help" Program Manager Group. Remove the Robtemp Directory Before you remove the WinHelp files, you can copy them to a diskette and distribute them to other Suprtool users. To delete all the WinHelp files and remove the Robtemp directory, use either the File Manager or the following DOS commands: cd \robtemp del *.* {delete all the files in Robtemp} cd .. rmdir robtemp {remove the Robtemp directory} Enhancements Every year we provide Suprtool/UX users with new features. The following section describes the new enhancements to Suprtool since the last major release. $Abs function Suprtool supports a $abs function which returns the absolute value of the number. For example if the field credit contains the value -547.83, the $abs function will return 547.83. This function will work on a field or even an expression such as: >if $abs(credit / 100 * 1.07) This function will also work in the extract command: >def newcredit,1,4,double >ext newcredit = $abs(newcredit / 100 * 1.07) $Days function Suprtool supports a $days function which will convert any supported date to a Julian Day number. (the number of days since 4713 BC). This allows for Date arithmetic, in which you can calculate the difference between two dates, even if they have dissimilar formats. For example you could find all orders that were not shipped within 30 days of being ordered. >form ORDFILE File: ORDFILE (SD Version B.00.00) Entry: Offset ORDER-DATE x8 1 <> SHIP-DATE X8 9 <> ORDER-NUMBER X6 17 Limit: 10000 EOF: 15 Entry Length: 23 Blocking: 16 >in ORDFILE >if $days(SHIP-DATE) - $days(ORDER-DATE) >=30 >list >xeq IN=15, OUT=4. CPU-Sec=1. Wall-Sec=1. As with the $stddate function, if a date is not a valid date then the result of the $days function will be zero. Similar to the $stddate function the $days function is also available to the extract command. You can convert any supported date to a Julian day number in the following manner. >in ordfile >def ship-days,1,4,double >def order-days,1,4,double >ext order-no >ext ship-days=$days(ship-date) >ext order-days=$days(order-date) >out neword,link >xeq IN=15, OUT=15. CPU-Sec=1. Wall-Sec=1. If an invalid date is encountered the value that is extracted will be zero. $Truncate function Suprtool supports a $truncate function which returns the number to the left of a decimal place. No rounding will take place. For example if the field stddev contains the value 547.83, the $truncate function will return 547. This function will work on a field or even an expression such as: >if $truncate(stddev / 100 * 1.07) This function will also work in the extract command: >def newdev,1,4,double >ext newdev = $truncate(stddev / 100 * 1.07) Field Names Suprtool now allows the "$" character to be used in field names. This was done to allow some users read databases used in the BAAN MRP application which uses the '$' character in all of it's item names. If Command The If command previously only supported patterns or fields of only up to 256 characters for a pattern matching operation. This restriction is no longer in effect. >in long >def a,1,1000 >if a==" Company " >list >xeq Item Command - Date The Item command now has two new date formats, these date formats are EDSDATE and JulianDay. EDSDATE The Item command now supports a new date format called EDSDATE, which is a date in a format similar to yyymmdd, where the first digit represents the century. The first digit in the EDSDATE is either 0 or 1, where 0 represents a century of 19 and 1 represents a century of 20. These date formats are available as either a double integer or a Packed field. >item order-date,date,edsdate JulianDay Another new date, called JulianDay has been added to the Item command. The JulianDay number is the absolute count of the days that have elapsed since Noon 1 January 4713 BC on the Julian Calendar. Typically Julian Day Numbers refer to integer number corresponding to whole days, while the Julian Date may mean an integer plus decimal that brings the Julian count down to precise parts of a day. Suprtool supports the "JulianDay" number and does not attempt to support an hour or point in the day. This date format is available for a double integer or double logical data type. >item daydate,date,julianday Item Command - PHDate8 PHDate8 PowerHouse versions 8.19 and higher have changed their Phdate format stored in a single integer (j1) container. The allowed range of values for the year is now 00 - 127. The Item command has been enhanced to support this new format: >item daydate,date,phdate8 Given the fact that many users may have a lot of Suprtool code with references to the Item command we have provided a Set command to change: >item daydate,date,phdate to mean: >item daydate,date,phdate8 The set command is: >set date MapToPhdate8 on This Set command only changes the reference to phdate to phdate8 in the Item command, it does not change references that already exist in self-describing files nor does it change the data. Set Command - Date A new Set command has been added to help change any Item command reference to phdate to mean phdate8, for assistance in converting to the newer phdate format found in PowerHouse version 8.19 and higher. The Set command is: >set date MapToPhdate8 on This only changes the reference to phdate8 in the Item command, it does not change references that already exist in self-describing files nor does it change the data. Suprlink and STExport Suprlink and STExport now support filenames of up to 240 characters in the Input, Output and Link commands . Suprlink and STExport are now capable of reading and writing files greater than 2 gigabytes. Bugs Fixed $stddate and phdate. The $stddate function will now apply the cutoff rules for the phdate format in small-int (I1 & J1) data fields. Sort Command. The Sort function attempts to use less heap resources when attempting to sort files greater than 2 gigabytes.