Professional Documents
Culture Documents
Copyright
Licensed Materials - Property of IBM
© Copyright IBM Corp. 1982, 2010.
US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
IBM, the IBM logo, ibm.com, Cognos, Axiant, and Powerhouse are trademarks or registered trademarks of International Business Machines
Corp., in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of
IBM trademarks is available on the Web at www.ibm.com/legal/copytrade.shtml.
Microsoft, Windows, Windows NT, and the Windows logo are trademarks of Microsoft Corporation in the United States, other countries, or
both.
Linux is a registered trademark of Linus Torvalds in the United States, other countries, or both.
UNIX is a registered trademark of The Open Group in the United States and other countries.
Table of Contents
Overview
® ® ®
This document describes how to plan your migration of IBM Cognos PowerHouse 4GL
® ® ® ®
applications from OpenVMS to a UNIX , Linux , or Microsoft Windows platform. It is
intended for system managers and developers who are familiar with the OpenVMS environment
and have a basic knowledge of UNIX, Linux, or Windows.
This document targets migrations from PowerHouse 4GL 8.40. If you are migrating from a prior
version, you may encounter additional issues due to version differences. We recommend that you
review these differences in the following documents:
• IBM Cognos PowerHouse 4GL Version 8.30 for OpenVMS Upgrade Guide
• IBM Cognos PowerHouse 4GL New Features
• IBM Cognos PowerHouse 4GL Release Notes
Unless otherwise indicated, where "Windows" appears in the documentation, it applies to the
Microsoft Windows operating systems. And unless otherwise indicated, where "relational
database" appears in the documentation, it refers to a relational database management system.
Chapter 1, "Migration Choices", gives an overview of the types of migration covered in this
guide. It also identifies the factors which will influence your choices for each type of migration.
Chapter 2, "The Target Platform: UNIX or Linux", discusses differences between OpenVMS and
UNIX or Linux that will have to be addressed during the migration.
Chapter 3, "The Target Platform: Windows", discusses differences between OpenVMS and
Windows that will have to be addressed during the migration.
Chapter 4, "The File Systems", contains a separate section for each of the OpenVMS file systems:
RMS ISAM (Indexed), relational, and RMS (Direct, Relative, Sequential). Each section lists the
target file systems available for the given source file system, and then discusses the work involved
in migrating between the two file systems.
Chapter 5, "The Migration Plan", describes the 12-step plan to perform the migration, including
everything from identifying training needs to editing data definitions. This is shown both with and
without the Axiant 4GL migration tools.
Getting Help
For more information about using this product or for technical assistance, go to
http://www.ibm.com/support. Under Choose support type, select Information Management, then
under Choose a product, select Cognos Application Development Tools. Under Cognos
Application Development Tools support, click Documentation.
Objective Document
Install The IBM Cognos PowerHouse 4GL Getting Started document provides
PowerHouse 4GL step-by-step instructions on installing PowerHouse 4GL.
Review changes The IBM Cognos PowerHouse 4GL Release Notes document provides
and new features information on supported environments, changes, and new features for the
current version.
Get detailed The IBM Cognos PowerHouse 4GL Reference documents provide detailed
reference information about the PowerHouse language and each PowerHouse
information for component.
PowerHouse 4GL The documents are
• IBM Cognos PowerHouse 4GL PowerHouse Rules
• IBM Cognos PowerHouse 4GL PDL and Utilities Reference
• IBM Cognos PowerHouse 4GL PHD Reference (OpenVMS)
• IBM Cognos PowerHouse 4GL PowerHouse and Relational Databases
• IBM Cognos PowerHouse 4GL QDESIGN Reference
• IBM Cognos PowerHouse 4GL QUIZ Reference
• IBM Cognos PowerHouse 4GL QTP Reference
Objective Document
Start using The IBM Cognos PowerHouse Web Planning and Configuration document
PowerHouse Web introduces PowerHouse Web, provides planning information and explains
how to configure the PowerHouse Web components.
Important: This document should be the starting point for all PowerHouse
Web users.
Install The IBM Cognos PowerHouse Web Getting Started document provides
PowerHouse Web step-by-step instructions on installing PowerHouse Web.
Review changes The IBM Cognos PowerHouse Web Release Notes document provides
and new features information on supported environments, changes, and new features for the
current version.
Get detailed The IBM Cognos PowerHouse Web Developer’s Guide document provides
information for detailed reference material for application developers.
developing
PowerHouse Web
applications
Objective Document
Administer The PowerHouse Web Administrator Online Help, available from within
PowerHouse Web the PowerHouse Web Administrator, provides detailed reference material to
help you during PowerHouse Web configuration.
Objective Document
Install Axiant 4GL The IBM Cognos Axiant 4GL Web Getting Started document provides
step-by-step instructions on installing Axiant 4GL.
Review changes The IBM Cognos Axiant 4GL Release Notes document provides
and new features information on supported environments, changes, and new features for the
current version.
Get an The A Guided Tour of Axiant 4GL document contains hands-on tutorials
introduction to that introduce the Axiant 4GL migration process and screen customization.
Axiant 4GL
Get detailed The Axiant 4GL Online Help, available from within Axiant 4GL, provides
reference a detailed reference guide to Axiant 4GL.
information on
Axiant 4GL
Supported Environments
For the latest supported environments information, go to http://www.ibm.com/support. Under
Choose support type, select Information Management, then under Choose a product, select
Cognos Application Development Tools. Under Cognos Application Development Tools Support,
under Additional Support Links, click Cognos ADT Software Environments.
This introductory chapter gives an overview of the types of migration covered in this guide.
Depending on your application, you may be able to make your migration choices directly from
this top-level chapter, or you may need to go into the detail chapters to aid in the decisions. In
either case, you can use the detail chapters that follow to understand and estimate the scope of
work involved in the migration.
Have you already decided on a file system which is only present on one of the platforms?
(Note that a relational database does not have to be on the same platform that is running
your PowerHouse 4GL application. For example, an application on Windows can use
Oracle on UNIX.)
• End-user UI
Have you already decided on using the Windows GUI (using Axiant 4GL)? This only runs
on Windows (although the server could be on UNIX in a thin-client setup).
For detailed information on differences in PowerHouse 4GL between OpenVMS and UNIX or
Linux, see (p. 13).
For detailed information on differences in PowerHouse 4GL between OpenVMS and Windows,
see (p. 27).
Moving Forward
"The Target Platform: UNIX or Linux" (p. 13) describes the changes you may have to make in
your PowerHouse 4GL application when moving to UNIX or Linux.
"The Target Platform: Windows" (p. 27) describes the changes you may have to make in your
PowerHouse 4GL application when moving to Windows.
"The File Systems" (p. 41) describes the changes you may have to make in your PowerHouse 4GL
application when changing to the various file systems on UNIX, Linux, or Windows.
"The Migration Plan" (p. 53) describes the 12-step plan to actually perform the migration. This
identifies everything from identifying training needs to editing data definitions.
This chapter identifies the differences between the OpenVMS and UNIX and Linux platforms that
have to be addressed during the migration of a PowerHouse 4GL application. It also identifies the
differences within PowerHouse 4GL between the two platforms.
For information on differences specifically due to a change in file systems, see "The File
Systems" (p. 41).
Many of the differences between platforms require changes to file names as part of the migration.
The Axiant 4GL migration tools can perform many of these changes automatically. For
information on this and other aspects of actually moving your application from OpenVMS to
UNIX or Linux, see "The Migration Plan" (p. 53).
The command interface on UNIX and Linux is known as a shell. Two of the most popular shells
are the Bourne Shell (of which the Korn Shell is a superset) and the C Shell. PowerHouse 4GL
works equally under either shell. The only difference is that you use different shell commands
within your command scripts (which replace DCL command files), depending on the shell you are
running under.
Platform Differences
Directory Paths
UNIX and Linux use directories (folders) similar to OpenVMS, with the following differences:
• Directories are separated by forward slashes:
[USER1.REPORTS.SOURCE] becomes /user1/reports/source/
• The syntax for device names is the same as for directories and files:
DISK1:[USER1]REPORT.QZS becomes /disk1/user1/report.qzs
File Names
Case Sensitivity
Unlike OpenVMS, the UNIX and Linux operating systems differentiate between lowercase and
uppercase. Therefore any references to physical file names within your dictionary, source code,
and command files must be consistent with the physical file name.
For example, the file names MYFILE.qks, Myfile.qks and myfile.qks do not refer to the same
physical file under UNIX and Linux.
The UNIX and Linux standard is for all names to be lowercase. We recommend that you
eventually follow this practice, renaming your files to lowercase. However, you may wish to do
this at some future time, after your migration is successful. This reduces the number of
mismatches by accidentally referencing a file with the incorrect case.
Tip: Since UNIX and Linux operating system commands are generally in lowercase, most work on
UNIX and Linux is done with the keyboard Caps Lock key turned off.
For information on how case sensitivity affects PowerHouse 4GL, see (p. 18).
Length
OpenVMS file names are generally restricted to 78 characters in length, depending on the disk
type. All versions of UNIX and Linux allow more than that, usually 128 or 255, so you do not
have to shorten any file names.
Similarly, OpenVMS path names (for example, [NIGHTRUN.SALES.CORPORATE]) are
restricted to 78 characters in length, whereas UNIX and Linux path names allow up to 1023
characters.
Logical Names
OpenVMS applications, including PowerHouse 4GL, make frequent use of logical names to point
applications to files of different names or locations without editing the application. Environment
variables are the equivalent on UNIX and Linux.
You need to define these environment variables to match your OpenVMS equivalents, usually
defined within command files. For information on converting command files, see "Operating
System Commands" (p. 14).
For information on the command files for PowerHouse 4GL designated files (such as the default
PowerHouse 4GL resource file), see "Designated Files and Environment Variables" (p. 18).
EXIT EXIT
eof
In the UNIX and Linux script, <<eof redirects the command input to the rest of the script until
encountering the eof string.
Path
On UNIX and Linux, an environment variable named "path" indicates which directories should
be searched through when the user (or a program) invokes the name of a command file.
OpenVMS has no equivalent to this variable (although you can set up a search path using a logical
name).
Be sure to modify the path variable for your user accounts to point to the directories containing
your command files. For example, set path = ($path /mgr_scripts/) if you are using the
Bourne shell, or setenv PATH $PATH:/mgr_scripts/ if you are using the C shell.
System Management
The change in platforms also means changes in application management. In particular, review the
methods and policies currently used for the following:
• application and data security
• backup, recovery, and data distribution
• software update distribution
• user interface
• end-user support
• capacity planning and performance management
File Versioning
UNIX and Linux do not support automatic multi-versioning of files (filename1.qks;3). All
applications that rely on access to previous versions of files should be reviewed and revised to
make copies of files before changing or to prevent changing them through file access control.
This will also result in different prompts appearing when you build or save a program file. Instead
of being asked to create a new version of a file, you are asked if you want the old one deleted.
Consider the example of CREATE DICTIONARY in PDL:
• OpenVMS (PDL): The file (name) already exists. Create new one? [Y/N]
OpenVMS (PHDPDL): Dictionary (name) already exists. Create a new version? [Y/N]
• UNIX and Linux: The file (name) already exists. Is it OK to delete? [Y/N]
Subfiles
On UNIX and Linux, as on OpenVMS, the dictionary information for a subfile is stored in a
separate file from the data. Thus each name.sf has a corresponding name.sfd. The same is true for
portable subfiles, name.ps and name.psd. Portable subfiles have their data written in an ASCII
format, which facilitates porting them between platforms.
When moving portable subfiles from OpenVMS to UNIX or Linux, you must ensure that the tool
transferring the files (such as FTP) does not insert a linefeed character at the end of each record.
For more information, see "The Migration Plan" (p. 53).
Subfile Locations
On OpenVMS, temporary subfiles are held in the SYS$SCRATCH directory (unless given a path
in the code). On UNIX or Linux, starting a PowerHouse 4GL component session creates a
temporary directory, phnnnn.tmp, to hold temporary subfiles and files. This directory is deleted
when the PowerHouse 4GL component session ends. This directory is unique for each logon
session, so two users running the same multi-pass report or multi-pass run do not read each
other’s temporary subfiles.
As on OpenVMS, temporary subfiles on UNIX and Linux are no longer available when you exit
the component. So an application that writes a temporary subfile in QTP then exits QTP and tries
to read that subfile in QUIZ does not work on either system.
As of version 8.43E for UNIX and Linux, you can tell QUIZ and QTP to retain temporary subfiles
by using the PHTEMPKEEP environment variable with the PHTEMP environment variable. If
PHTEMPKEEP is set, temporary subfiles are created in the location specified by the PHTEMP
environment variable so they are readily available for subsequent compilation passes. If you set
PHTEMPKEEP, you should delete the temporary subfiles when they are no longer required.
Case Sensitivity
As mentioned on (p. 13), the UNIX and Linux operating systems differentiate between lowercase
and uppercase, so any references to physical file names within your dictionary, source code, and
command files must be consistent with the physical file name. In particular, note that PowerHouse
4GL executables and file extensions must be in lowercase.
For example,
RUN COMMAND "QTP AUTO=NITERUN.QTC"
must become
RUN COMMAND "qtp auto=NITERUN.qtc"
Or you can downshift the complete name:
RUN COMMAND "qtp auto=<path>/niterun.qtc"
The SYSTEM OPTIONS SHIFT as well as the SET <shift options> apply to relational columns
and tables but not physical file names. So the QDESIGN code, "SCREEN Test", results in a
mixed-case file named Test.qkc on UNIX or Linux.
Interrupt Control
The user can interrupt prompting within PowerHouse 4GL components by pressing the interrupt
keystroke in response to a prompt. On OpenVMS this can be Ctrl-C or Ctrl-Y; on UNIX and
Linux this is commonly Ctrl-C.
$POW
PowerHouse 4GL on UNIX and Linux does not use the POW(ERHOUSE) menu system as on
OpenVMS. The various PowerHouse 4GL components and utilities are run directly from OS
commands (as they can be on OpenVMS as well). The following table identifies the UNIX or
Linux OS commands equivalent to the POW Menu options:
PDL
OpenVMS, UNIX, and Linux support the full PDL syntax, so the only issues to be aware of are
platform differences.
FILE
The following FILE statement options are OpenVMS-specific. They can be dropped without
replacement, as they have no UNIX or Linux equivalents:
CAPACITY
RECORD FORMAT
SCOPE
SUPERSEDE
INDEX
The NULL option of the INDEX statement is only valid on OpenVMS. It is not needed or
available on UNIX or Linux.
Item Datatypes
The Item datatypes G_FLOAT and VMSDATE are only valid on OpenVMS. They can be found in
ITEM statements as well as ELEMENT x DEFAULT ITEM DATATYPE statements and USAGE
statements. On UNIX and Linux, use FLOAT SIZE 8 and DATETIME.
Be aware that you may face a loss of data when migrating any floating point numbers from one
platform to another. This is due to a loss of precision or significance; for example, 0.20 may be
stored as 0.199999....
For more information on floating point data loss, see the IBM Cognos PowerHouse 4GL
PowerHouse Rules document.
SET PRINT|NOPRINT
This option is only valid in PHDPDL. It has no equivalent on UNIX or Linux.
QSHOW
SET GENERATE DEVICE
SET GENERATE DEVICE (for terminal, printer, or disc) is only valid on OpenVMS. On UNIX
and Linux, as on OpenVMS, the default for a GENERATE command is to write PDL to
qshogen.pdl.
QUTIL
SET FDL|NOFDL
FDL files do not exist on UNIX or Linux, so this command is not valid.
QDESIGN/QUICK
Program Parameters
The following program parameters exist on OpenVMS but not on UNIX or Linux. They can be
dropped without replacement, as they have no UNIX or Linux equivalents.
BROADCAST
DCL|NODCL
DICTTYPE
DIRECT_FILE_BASE_ZERO
FASTREAD
FDL|NOFDL
INTSIZE6|NOINTSIZE6
NOUICBRACKETS
TERMPOLL|NOTERMPOLL
TRUSTED|NOTRUSTED
VMSDATE
DO EXTERNAL
Your application system may use 3GL programs (such as COBOL, Fortran, or C) either at the OS
level or from within PowerHouse 4GL DO EXTERNAL calls. As with command files, the first
thing to do is assess whether you really need to bring these forward. They may be vestiges of older
systems, no longer needed.
Rewriting 3GL programs in PowerHouse 4GL code is not recommended, especially if they
perform complex mathematical calculations. Instead, find a compiler for the new UNIX or Linux
environment. If you cannot find a compiler, consider rewriting the programs in C or C++.
You can remove the DESCRIPTOR option from your DO EXTERNAL calls on UNIX or Linux,
because it is OpenVMS-specific. All other DO EXTERNAL parameters are identical between
OpenVMS, UNIX, and Linux. However, they can hold different values and have different limits,
due to platform differences. For more information, see the IBM Cognos PowerHouse 4GL
QDESIGN Reference.
The UNIX and Linux equivalent to the OpenVMS BUILDEXTERNAL command procedure is a
script named BuildExternal. For more information, see the IBM Cognos PowerHouse 4GL
QDESIGN Reference.
3GL Locking
3GL programs on OpenVMS are able to bypass PowerHouse 4GL file level locking. This is
because PowerHouse 4GL components follow the cooperative locking strategy of the OpenVMS
Distributed Lock Manager (DLM), but 3GL programs you code yourself may not. PowerHouse
4GL on OpenVMS provides its own 3GL routines you can use to ensure cooperative locking.
UNIX and Linux locking is absolute rather than cooperative. Therefore the 3GL routines
provided for PowerHouse 4GL on OpenVMS are not needed on UNIX or Linux.
QKGO
To start QKGO on UNIX and Linux, enter the qkgo command. On OpenVMS, you may have
done this through the qkgomaint command or the PHD Screens.
If terminal (TIC) information is specified in QKGO, OpenVMS creates a context-binding file (for
example, FILENAMEB.DAT) and a key sequence file (for example, FILENAMEK.DAT) and one
or more terminal-group files (for example, FILENAMET.DAT). On UNIX and Linux, two files are
created for all three of these cases: filenameb.dat and filenameb.idx, filenamek.dat and
filenamek.idx, and filenamet.dat and filenamet.idx. PowerHouse 4GL must be licensed for
C-ISAM data access to do this.
On UNIX and Linux, the QKGO environment variable provides the same functionality as the
First screen field in the Construction and Maintenance Screen. This is equivalent to the QKGO
logical name on OpenVMS.
Similarly, on UNIX and Linux, the PHD environment variable provides the same functionality as
the Dictionary File field in the Construction and Maintenance Screen. This is equivalent to the
SETDICT OS command on OpenVMS.
PowerHouse 4GL on OpenVMS, UNIX, and Linux employs deadlock protection to avoid a
’deadly embrace’ between two processes attempting to lock the same file. However the manner in
which they do so is different. On OpenVMS, this is affected by QKGO parameters LOCK MESSAGE
WAIT and LOCK REQUEST WAIT. On UNIX and Linux, this is affected by QKGO parameters
LOCK ATTEMPTS, LOCK RETRY INTERVAL, and LOCK UNCONDITIONAL. For further information,
see the IBM Cognos PowerHouse 4GL QDESIGN Reference.
The following Execution Time Parameters exist on OpenVMS but not on UNIX or Linux. They
can be dropped without replacement, as they have no UNIX or Linux equivalents.
DRIVER
LOCK MESSAGE WAIT
LOCK REQUEST WAIT
MAX. PAGED MEMORY
SCREEN SECTION
SECONDARY BLOCKS
SELECTION SIZE
The Execution Time Parameter Field terminators controls data input. The default on
OpenVMS is F (full field), and the default on UNIX and Linux is M (manual).
Dynamic Function Keys are terminal specific rather than platform specific. On OpenVMS, DFK1
through DFK4 are mapped by default to GOLD1 through GOLD4. You maintain this mapping
on UNIX and Linux if you use a VT terminal (or terminal emulator).
The Color Display Attributes screen is only available on OpenVMS.
Editing a QUICK Initialization File (.QKI) is an alternative to using the QKGO screen system. If
you have a .QKI file on OpenVMS, it can be ported to UNIX or Linux as a text file. PowerHouse
4GL on UNIX and Linux ignores any OpenVMS specific parameters.
QTP
OpenVMS Syntax
The following statement options are OpenVMS-specific, and are not supported on UNIX or
Linux:
CHOOSE... SYSTEMVALUE [LOGICAL|SYMBOL]
SET DICTIONARY [TYPE PHD|PDC]
SET FILE ... SEMIEXCLUSIVE
SET FILE SIGNAL|NOSIGNAL [ON CLOSE]
SET FILE WAIT|NOWAIT [ON SEND|RECEIVE|FULL]
SORT ON ... RETAIN ORDER
SET JOB
On OpenVMS, operating system commands prefixed with a dollar sign ($) execute immediately.
Operating system commands prefixed with two dollar signs ($$) are not executed immediately but
are written to QTPSAVE.
On UNIX and Linux, operating system commands prefixed with a single exclamation mark (!)
suspend the current process, and execute the Shell command. Operating system commands
prefixed by two exclamation marks (!!) write the Shell command to the currently active save file
with one exclamation mark. For examples, see the IBM Cognos PowerHouse 4GL QTP
Reference.
All SET JOB options are OpenVMS-specific and are not supported on UNIX or Linux. They are:
AFTER [absolute-time][+|- delta-time]
[NO]CHARACTERISTICS number|string[[,]number|string]...
CPUTIME n
HOLD|NOHOLD
IDENTIFY|NOIDENTIFY
KEEP|NOKEEP
LOGFILE [name]|NOLOGFILE
NAME filespec
NOTIFY|NONOTIFY
PARAMETERS string [,string]...
PRINTER name|NOPRINTER
PRIORITY n
QUEUE queuename
RESTART|NORESTART
USER username
WSDEFAULT n
WSEXTENT n
WSQUOTA n
Subfiles
Indexed subfiles require that PowerHouse 4GL be licensed for C-ISAM data access.
As discussed in Chapter 4, First Record, Direct Files, direct files begin with record 1 on OpenVMS
but with record 0 on UNIX and Linux. Since subfiles are direct files, ACCESS ... LINK TO
RECORD n of *subfile1 becomes ACCESS ... LINK TO RECORD n-1 of *subfile1.
On OpenVMS, SUBFILE ... FORMAT permits values of 4|7|8, whereas valid values on UNIX and
Linux are 3|5|6|7|8. Since you are migrating to a new platform and format, you should remove the
FORMAT parameter.
Default Printer
On OpenVMS, the default printer is SYSPRINT or SYS$PRINT. On UNIX and Linux, the default
printer is obtained from the value of the environment variable, PH_PRINTER. If this variable is
not set, the system default printer is used.
QUIZ
OpenVMS Syntax
The following statement options are OpenVMS-specific, and are not supported on UNIX or
Linux:
CHOOSE... SYSTEMVALUE [LOGICAL|SYMBOL]
SET DICTIONARY [TYPE PHD|PDC]
SET FILE WAIT|NOWAIT [ON SEND|RECEIVE|FULL]
SORT ON ... RETAIN ORDER
SET JOB
On OpenVMS, operating system commands prefixed with a dollar sign ($) execute immediately.
Operating system commands prefixed with two dollar signs ($$) are not executed immediately but
are written to QUIZSAVE.
On UNIX and Linux, operating system commands prefixed with a single exclamation mark (!)
suspend the current process, and execute the Shell command. Operating system commands
prefixed by two exclamation marks (!!) write the Shell command to the currently active save file
with one exclamation mark. For examples, see the IBM Cognos PowerHouse 4GL QUIZ
Reference.
All SET JOB options are OpenVMS-specific and are not supported on UNIX or Linux. They are:
AFTER [absolute-time][+|- delta-time]
[NO]CHARACTERISTICS number|string[[,]number|string]...
CPUTIME n
HOLD|NOHOLD
IDENTIFY|NOIDENTIFY
KEEP|NOKEEP
LOGFILE [name]|NOLOGFILE
NAME filespec
NOTIFY|NONOTIFY
PARAMETERS string [,string]...
PRINTER name|NOPRINTER
PRIORITY n
QUEUE queuename
RESTART|NORESTART
USER username
WSDEFAULT n
WSEXTENT n
WSQUOTA n
Subfiles
As discussed in Chapter 4, First Record, Direct Files, sequential and direct files begin with record
1 on OpenVMS but with record 0 on UNIX and Linux. As subfiles are direct files, ACCESS ...
LINK TO RECORD n of *subfile1 becomes ACCESS ... LINK TO RECORD n-1 of
*subfile1.
Indexed subfiles require that PowerHouse 4GL be licensed for C-ISAM data access.
On OpenVMS, SUBFILE ... FORMAT permits values of 4|7|8, whereas valid values on UNIX and
Linux are 3|5|6|7|8. Since you are migrating to a new platform and format, you should remove the
FORMAT parameter.
Default Printer
On OpenVMS, the default printer is SYSPRINT or SYS$PRINT. On UNIX and Linux, the default
printer is obtained from the value of the environment variable, PH_PRINTER. If this variable is
not set, the system default printer is used.
COPIES
FLAG|NOFLAG
FORMS
[NO]HOLD
[NO]IDENTIFY
[NO]LOWERCASE
[NO]CHARACTERISTIC
NOTE
[NO]NOTIFY
[NO]OPERATOR
PRIORITY QUEUE
[NO]RESTART
[NO]TRAILER
USER
PDL
Indexes
The SEGMENT statement for C-ISAM files on UNIX and DISAM files on Linux allow a
DESCENDING option, not available on OpenVMS at the segment level. This indicates the order
in which segments are stored in the index.
QDESIGN/QUICK
Backwards Access
UNIX and Linux allow applications to read data records in reversed sequence. BACKWARDS is
an option on the GET verb, FIELD... LOOKUP, and the WHILE RETRIEVING verb.
QKGO
Execution Time Parameters
The following Execution Time Parameters exist on UNIX and Linux but not on OpenVMS. You
may want to investigate their value to your application. For further information, see the IBM
Cognos PowerHouse 4GL QDESIGN Reference.
EXT. SUBROUTINES, HP TERMINAL HAS LDW, LOCK ATTEMPTS, LOCK RETRY INTERVAL, LOCK
UNCONDITIONAL
QTP
SUBFILE
The INDEX and SEGMENT options of the SUBFILE statement for indexed subfiles allow the
DESCENDING option. This indicates the order in which segments are stored in the index.
QUIZ
SET SUBFILE
The INDEX and SEGMENT options of the SET SUBFILE statement for indexed subfiles allow the
DESCENDING option. This indicates the order in which segments are stored in the index.
Moving Forward
"The File Systems" (p. 41) describes the changes you may have to make in your PowerHouse 4GL
application when changing to the various file systems on UNIX, Linux, or Windows.
"The Migration Plan" (p. 53) describes the 12-step plan to perform the migration. This identifies
everything from identifying training needs to editing data definitions.
This chapter identifies the differences between the OpenVMS and Windows platforms that have
to be addressed during the migration of an IBM Cognos PowerHouse 4GL application. It also
identifies the differences within PowerHouse 4GL between the two platforms.
For information on differences specifically due to a change in file systems, see "The File
Systems" (p. 41).
Many of the differences between platforms require changes to file names as part of the migration.
The Axiant 4GL migration tools can perform many of these changes automatically. For
information on this and other aspects of actually moving your application from OpenVMS to
Windows, see "The Migration Plan" (p. 53).
Platform Differences
Folder Separators
Windows uses folders similar to OpenVMS. However folders are separated by backward slashes.
For example, the OpenVMS path
DISK1:[USER1.REPORTS.SOURCE]
would have a Windows equivalent of
C:\user1\reports\source\
File Names
Case Sensitivity
Like OpenVMS, Windows is not case sensitive. However, unlike OpenVMS, Windows allows
mixed case. In other words, TEST.qkc and test.qkc are considered the same name. For more
information, see "PowerHouse 4GL File Extensions" (p. 30).
Length
OpenVMS file names are generally restricted to 78 characters in length, depending on the disk
type. Windows allows 256 characters, so you do not have to shorten any file names.
Similarly, OpenVMS path names (for example, [NIGHTRUN.SALES.CORPORATE]) are restricted to
78 characters in length, whereas Windows path names allow up to 1023 characters.
Logical Names
OpenVMS applications, including PowerHouse 4GL, make frequent use of logical names to point
applications to files of different names or locations without editing the application. Environment
variables are the equivalent on Windows.
You need to define these environment variables to match your OpenVMS equivalents, usually
defined within command files. For information on converting command files, see "Operating
System Commands" (p. 28).
For information on the logical names for PowerHouse 4GL designated files (such as the default
PowerHouse 4GL resource file), see "Designated Files and Environment Variables" (p. 31).
EXIT EXIT
To execute: To execute:
SUBMIT QUIZRUN01.COM QUIZRUN01.BAT
(or select Run from the Start menu)
PATH
On Windows, a system-level environment variable named PATH indicates which folders should be
searched through when the user or a program invokes the name of a script. OpenVMS has no
equivalent to this variable, although you can set up a search path using a logical name.
The PowerHouse 4GL install procedures place the PowerHouse 4GL install locations into the
PATH variable. Hence you can call QUIZ, for example, by simply typing the command QUIZ from
within any folder you may be working in within your Command Prompt window.
Be sure to modify the PATH variable for your user accounts to point to the folders containing
your scripts.
System Management
The change in platforms also means changes in application management. In particular, review the
methods and policies currently used for the following:
• application and data security
• backup, recovery, and data distribution
• software update distribution
• user interface
• end-user support
• capacity planning and performance management
File Versioning
Windows does not support automatic multi-versioning of files (filename1.qks;3). All applications
that rely on access to previous versions of files should be reviewed and revised to make copies of
files before changing or to prevent changing them through file access control.
This also results in different prompts appearing when you build or save a program file. Instead of
being asked to create a new version of a file, you will be asked if you want the old one deleted.
Consider the example of CREATE DICTIONARY in PDL:
• OpenVMS (PDL): The file (name) already exists. Create new one? [Y/N]
OpenVMS (PHDPDL): Dictionary (name) already exists. Create a new version? [Y/N]
• Windows: The file (name) already exists. Is it OK to delete? [Y/N]
On Windows, though, if you run a PowerHouse 4GL component from the default Start menu
shortcuts, this location is the product install location, by default. You can change this location by
modifying the Start in property of the component shortcut.
To avoid saving your files in the Start in location when you run a component from a shortcut, run
the component from a Command Prompt window in which you have moved to the desired
location with a CD command.
Subfiles
On Windows, as on OpenVMS, the dictionary information for a subfile is stored in a separate file
from the data. Each name.sf has a corresponding name.sfd. The same is true for portable subfiles,
name.ps and name.psd. Portable subfiles have their data written in an ASCII format, which
facilitates porting them between platforms.
When moving portable subfiles from OpenVMS to Windows, you must ensure that the tool
transferring the files (such as FTP) does not insert a line feed character at the end of each record.
For more information, see "The Migration Plan" (p. 53).
Subfile Locations
On OpenVMS, temporary subfiles are held in the SYS$SCRATCH directory (unless given a path
in the code). On Windows, starting a PowerHouse 4GL component session creates a temporary
folder, phnnnn.tmp, to hold temporary subfiles and files. The temporary folder is created in the
location specified by the PHTEMP environment variable. This folder is deleted when the
PowerHouse 4GL component session ends. This folder is unique for each logon session, so two
users running the same multi-pass report or multi-pass run do not read each other’s temporary
subfiles.
As on OpenVMS, temporary subfiles on Windows are no longer available when you exit the
component. So an application that writes a temporary subfile in QTP then exits QTP and tries to
read that subfile in QUIZ does not work on either system.
As of version 8.41E for Windows, you can tell QUIZ and QTP to retain temporary subfiles by
using the PHTEMPKEEP environment variable with the PHTEMP environment variable. If
PHTEMPKEEP is set, temporary subfiles are created in the PHTEMP location so they are readily
available for subsequent compilation passes. If you set PHTEMPKEEP, you should delete the
temporary subfiles when they are no longer required.
Interrupt Control
The user can interrupt prompting within PowerHouse 4GL components by pressing the interrupt
keystroke in response to a prompt. On OpenVMS this can be Ctrl-C or Ctrl-Y; on Windows this is
commonly Ctrl-C.
$POW
PowerHouse 4GL on Windows does not use the POW(ERHOUSE) menu system as on OpenVMS.
The various PowerHouse 4GL components and utilities are run directly from OS commands (as
they can be on OpenVMS as well) within a Command Prompt window. The following table
identifies the Windows commands equivalent to the POW Menu options:
PDL
OpenVMS and Windows both support the full PDL syntax, so the only issues to be aware of are
platform differences.
FILE
The following FILE statement options are OpenVMS-specific. They can be dropped without
replacement, as they have no Windows equivalents:
CAPACITY
RECORD FORMAT
SCOPE
SUPERSEDE
INDEX
The NULL option of the INDEX statement is only valid on OpenVMS. It is not needed or
available on Windows.
Item Datatypes
The Item datatypes G_FLOAT and VMSDATE are only valid on OpenVMS. They can be found in
ITEM statements as well as ELEMENT x DEFAULT ITEM DATATYPE statements and USAGE
statements. On Windows, use FLOAT SIZE 8 and DATETIME.
You may face a loss of data when migrating any floating point numbers from one platform to
another. This is due to a loss of precision or significance; for example, 0.20 may be stored as
0.199999.... For more information on floating point data loss, see the IBM Cognos PowerHouse
4GL PowerHouse Rules document.
SET PRINT|NOPRINT
This option is only valid in PHDPDL. It has no equivalent on Windows.
QSHOW
SET GENERATE DEVICE
SET GENERATE DEVICE (for terminal, printer, or disc) is only valid on OpenVMS. On
Windows, as on OpenVMS, the default for a GENERATE command is to write PDL to
qshogen.pdl.
QUTIL
SET FDL|NOFDL
FDL files do not exist on Windows, so this command is not valid.
QDESIGN/QUICK
The Command Prompt
Because QUICK on Windows runs within a Console window (the Command Prompt) rather than
a terminal, the following areas of your application may be affected:
• handling of escape sequences
• use of fonts and line drawing
• adjusting the size of the QUICK window
• setting highlights and colors
Program Parameters
The following program parameters exist on OpenVMS but not on Windows. They can be
dropped without replacement, as they have no Windows equivalents.
BROADCAST
DCL|NODCL
DICTTYPE
DIRECT_FILE_BASE_ZERO
FASTREAD
FDL|NOFDL
INTSIZE6|NOINTSIZE6
NOUICBRACKETS
TERMPOLL|NOTERMPOLL
TRUSTED|NOTRUSTED
VMSDATE
DO EXTERNAL
Your application system may use 3GL programs (such as COBOL, Fortran, or C) either at the OS
level or from within QUICK DO EXTERNAL calls. As with scripts, the first thing to do is assess
whether you really need to bring these forward. They may be vestiges of older systems, no longer
needed.
Rewriting 3GL programs in PowerHouse 4GL code is not recommended, especially if they
perform complex mathematical calculations. Instead, find a compiler for the new Windows
environment. If you cannot find a compiler, consider rewriting the programs in C or C++.
You can remove the DESCRIPTOR option from your DO EXTERNAL calls on Windows,
because it is OpenVMS-specific. All other DO EXTERNAL parameters are identical between
OpenVMS and Windows, however they can hold different values and have different limits, due to
platform differences.
Note: The DO EXTERNAL call syntax on Windows has two formats or calling conventions,
named C and PASCAL. Check your 3GL provider to determine which of these two calling
conventions to use in the DO EXTERNAL call.
Windows has no equivalent to the OpenVMS BuildExternal command. On Windows, you
compile the external subroutines into DLLs.
3GL Locking
3GL programs on OpenVMS are able to bypass PowerHouse 4GL file level locking. This is
because PowerHouse 4GL components follow the cooperative locking strategy of the OpenVMS
Distributed Lock Manager (DLM), but 3GL programs you code yourself may not. PowerHouse
4GL on OpenVMS provides its own 3GL routines you can use to ensure cooperative locking.
Windows locking is absolute rather than cooperative. Therefore the 3GL routines provided for
PowerHouse 4GL on OpenVMS are not needed on Windows.
QKGO
To start QKGO on Windows, click the Start Menu, IBM Cognos PowerHouse 4GL <version>,
and then QKGO. On OpenVMS, this was done with the QKGOMAINT command or the PHD
Screens.
Windows has no terminal interface, just a command window. Therefore, the VTxxx-specific
terminal layout and function keys are not available on Windows.
On OpenVMS, the QKGO Maintenance system generates a different Terminal Interface
Configuration (TIC) file for each terminal type because the key codes are different. On Windows,
there is only one keyboard type for QUICK that corresponds to the PC keyboard.
If terminal (TIC) information is specified in QKGO, OpenVMS creates a context-binding file (for
example, FILENAMEB.DAT) and a key sequence file (for example, FILENAMEK.DAT) and one
or more terminal-group files (for example, FILENAMET.DAT). On UNIX and Linux, two files are
created for all three of these cases: filenameb.dat and filenameb.idx, filenamek.dat and
filenamek.idx, and filenamet.dat and filenamet.idx. To do this, PowerHouse 4GL must be licensed
for DISAM data access.
A default TIC file is also provided in the <installation_folder>\qkgo\resource folder. This TIC file
contains the key codes for all the keys and key combinations that can be mapped, as well as a set
of default key mappings that correspond to the PCANSI terminal type as defined for PowerHouse
4GL on UNIX and Linux. It can be modified as required to satisfy application requirements. To
access a TIC file, use the PHTICRS environment variable to point to the TIC file. It is
recommended that you make a copy of the default TIC file before modifying it. For more
information, see the IBM Cognos PowerHouse 4GL QDESIGN Reference.
On Windows, the QKGO environment variable provides the same functionality as the First screen
field in the QKGO Construction and Maintenance Screen. This is equivalent to the QKGO logical
name on OpenVMS.
Similarly, on Windows, the PHD environment variable provides the same functionality as the
Dictionary File field in the QKGO Construction and Maintenance Screen. This is equivalent to the
PHD logical name or the SETDICT OS command on OpenVMS.
PowerHouse 4GL on both OpenVMS and Windows employ deadlock protection to avoid a
’deadly embrace’ between two processes attempting to lock the same file. However the manner in
which they do so is different. On OpenVMS, this is affected by QKGO parameters LOCK
MESSAGE WAIT and LOCK REQUEST WAIT. On Windows, this is affected by QKGO
parameters LOCK ATTEMPTS, LOCK RETRY INTERVAL, and LOCK UNCONDITIONAL.
For further information, see the IBM Cognos PowerHouse 4GL QDESIGN Reference.
The following Execution Time Parameters exist on OpenVMS but not on Windows. They can be
dropped without replacement, as they have no Windows equivalents.
DRIVER
LOCK MESSAGE WAIT
LOCK REQUEST WAIT
MAX. PAGED MEMORY
SCREEN SECTION
SECONDARY BLOCKS
SELECTION SIZE
The Execution Time Parameters Field terminators controls data input. The default on
OpenVMS is F (full field), and the default on Windows is M (manual).
The Color Display Attributes Screen is only available on OpenVMS.
Editing a QUICK Initialization File (.QKI) is an alternative to using the QKGO screen system. If
you have a .QKI file on OpenVMS, it can be ported to Windows as a text file. PowerHouse 4GL
on Windows ignores any OpenVMS specific parameters.
QTP
OpenVMS Syntax
The following statement options are OpenVMS-specific, and are not supported on Windows:
CHOOSE... SYSTEMVALUE [LOGICAL|SYMBOL]
SET DICTIONARY [TYPE PHD|PDC]
SET FILE ... SEMIEXCLUSIVE
SET FILE SIGNAL|NOSIGNAL [ON CLOSE]
SET FILE WAIT|NOWAIT [ON SEND|RECEIVE|FULL]
SORT ON ... RETAIN ORDER
SET JOB
On OpenVMS, operating system commands prefixed with a dollar sign ($) execute immediately.
Operating system commands prefixed with two dollar signs ($$) are not executed immediately but
are written to QTPSAVE.
On Windows, operating system commands prefixed with a dollar sign ($) or a single exclamation
mark (!) suspend the current process, and execute the command. Operating system commands
prefixed by two dollar signs ($$) or two exclamation marks (!!) write the command to the
currently active save file with one exclamation mark. For examples, see the IBM Cognos
PowerHouse 4GL QTP Reference.
All SET JOB options are OpenVMS-specific and are not supported on Windows. They are:
AFTER [absolute-time][+|- delta-time]
[NO]CHARACTERISTICS number|string[[,]number|string]...
CPUTIME n
HOLD|NOHOLD
IDENTIFY|NOIDENTIFY
KEEP|NOKEEP
LOGFILE [name]|NOLOGFILE
NAME filespec
NOTIFY|NONOTIFY
PARAMETERS string [,string]...
PRINTER name|NOPRINTER
PRIORITY n
QUEUE queuename
RESTART|NORESTART
USER username
WSDEFAULT n
WSEXTENT n
WSQUOTA n
Subfiles
Indexed subfiles require that PowerHouse 4GL be licensed for DISAM data access.
As discussed in Chapter 4, First Record, Direct Files, direct files begin with record 1 on OpenVMS
but with record 0 on Windows. Since subfiles are direct files, ACCESS ... LINK TO RECORD n of
*subfile1 becomes ACCESS ... LINK TO RECORD n-1 of *subfile1.
On OpenVMS, SUBFILE ... FORMAT permits values of 4|7|8, whereas valid values on Windows
are 3|5|6|7|8. Since you are migrating to a new platform (and format), you should remove the
FORMAT parameter.
QUIZ
OpenVMS Syntax
The following statement options are OpenVMS-specific, and are not supported on Windows:
CHOOSE... SYSTEMVALUE [LOGICAL|SYMBOL]
SET DICTIONARY [TYPE PHD|PDC]
SET FILE WAIT|NOWAIT [ON SEND|RECEIVE|FULL]
SORT ON ... RETAIN ORDER
SET JOB
On OpenVMS, operating system commands prefixed with a dollar sign ($) execute immediately.
Operating system commands prefixed with two dollar signs ($$) are not executed immediately but
are written to QUIZSAVE.
On Windows, operating system commands prefixed by two dollar signs ($$) or two exclamation
marks (!!) write the Shell command to the currently active save file with one exclamation mark.
Operating system commands prefixed with a single exclamation mark (!) suspend the current
process, and execute the Shell command. For examples, see the IBM Cognos PowerHouse 4GL
QUIZ Reference.
All SET JOB options are OpenVMS-specific and are not supported on Windows. They are:
AFTER [absolute-time][+|- delta-time]
[NO]CHARACTERISTICS number|string[[,]number|string]...
CPUTIME n
HOLD|NOHOLD
IDENTIFY|NOIDENTIFY
KEEP|NOKEEP
LOGFILE [name]|NOLOGFILE
NAME filespec
NOTIFY|NONOTIFY
PARAMETERS string [,string]...
PRINTER name|NOPRINTER
PRIORITY n
QUEUE queuename
RESTART|NORESTART
USER username
WSDEFAULT n
WSEXTENT n
WSQUOTA n
Subfiles
As discussed in Chapter 4, First Record, Direct Files, sequential and direct files begin with record
1 on OpenVMS but with record 0 on Windows. As subfiles are direct files, ACCESS ... LINK TO
RECORD n of *subfile1 becomes ACCESS ... LINK TO RECORD n-1 of *subfile1.
Indexed subfiles require that PowerHouse 4GL be licensed for DISAM data access.
On OpenVMS, SUBFILE ... FORMAT permits values of 4|7|8, whereas valid values on Windows
are 3|5|6|7|8. Since you are migrating to a new platform (and format), you should remove the
FORMAT parameter.
Default Printer
On OpenVMS, the default printer is SYSPRINT or SYS$PRINT. On Windows, the printer
configuration for the current Windows session is used as the destination printer. To direct the
Report to another printer, change your printer configuration using the Control Panel. See your
Microsoft Windows documentation for information on printer configuration in Control Panel. Or
if you are running QUIZ from a Command Prompt window, you can specify the printer through
options on the Print command.
PDL
Indexes
The SEGMENT statement for DISAM files on Windows allows a DESCENDING option, not
available on OpenVMS at the segment level. This indicates the order in which segments are stored
in the index.
QDESIGN/QUICK
Backwards Access
Windows allows data records to be read in reversed sequence. BACKWARDS is an option on the
GET verb, FIELD... LOOKUP, and the WHILE RETRIEVING verb.
QKGO
Execution Time Parameters
The following Execution Time Parameters exist on Windows but not on OpenVMS. You may
want to investigate their value to your application. For further information, see the IBM Cognos
PowerHouse 4GL QDESIGN Reference.
EXT. SUBROUTINES, LOCK ATTEMPTS, LOCK RETRY INTERVAL, LOCK UNCONDITIONAL
QTP
SUBFILE
The INDEX and SEGMENT options of the SUBFILE statement for indexed subfiles allow the
DESCENDING option. This indicates the order in which segments are stored in the index.
QUIZ
SET SUBFILE
The INDEX and SEGMENT options of the SET SUBFILE statement for indexed subfiles allow the
DESCENDING option. This indicates the order in which segments are stored in the index.
Moving Forward
"The File Systems" (p. 41) describes the changes you may have to make in your PowerHouse 4GL
application when changing to the various file systems on Windows or Windows.
"The Migration Plan" (p. 53) describes the 12-step plan to perform the migration. This identifies
everything from identifying training needs to editing data definitions.
This chapter contains a separate section for each of the OpenVMS file systems: RMS ISAM, RMS
(sequential, direct, and relative) and relational. In each section, we identify the target file systems
available for the given source file system, and then discuss the work involved in migrating between
the two file systems.
We discuss what must change during a migration in both the dictionary and the programs. Where
differences are major, we discuss details of specific target file systems.
This chapter discusses the PowerHouse 4GL differences between file systems. For a discussion of
the relative advantages of each file system, see "Migration Choices" (p. 9). For information on
moving the application files between platforms and other aspects of the overall migration process,
see "The Migration Plan" (p. 53). For more detailed information on how PowerHouse 4GL
works with relational databases, see the IBM Cognos PowerHouse 4GL PowerHouse and
Relational Databases document or consider attending the PowerHouse Relational Interface
training (Parts I and II).
Indexed to Indexed
Both C-ISAM on UNIX and DISAM on Linux and Windows accept the vast majority of your PDL
syntax for RMS. This means that few changes are required to your application programs.
Datatype Mappings
PowerHouse 4GL makes few restrictions on datatype usage for keys and indexes. File systems, on
the other hand, are much more restrictive as to what is available, so PowerHouse 4GL maps its
datatypes to the best match available when the file is generated using QUTIL. In some cases, a
mapping that works well in RMS may not work well with C-ISAM or DISAM. You should review
your key and index datatypes and adjust them where appropriate. A table of these datatype
mappings can be found on (p. 50).
PDL
To change a PDL FILE statement to work with C-ISAM or DISAM, change the TYPE option from
RMS to CISAM (no hyphen) or DISAM. (On UNIX and Linux, the TYPE clause can optionally be
omitted.) For example:
FILE BILLINGS ORGANIZATION INDEXED TYPE CISAM ...
The following FILE options do not apply to C-ISAM or DISAM and must be removed:
• CAPACITY n (C-ISAM and DISAM files automatically expand as needed)
• RECORD FORMAT
• SUPERSEDE (C-ISAM and DISAM do not support file versioning)
DISAM Opens
Unlike RMS ISAM or C-ISAM, a DISAM file opened for Write or Append cannot be read until it
is closed. Review your programs to see if they are reading any RMS files opened for Write or
Append, and either issue a Close before the read or postpone the read.
Oracle Oracle
Sybase Sybase
You need to make several types of changes to your application source files, both data definitions
and programs. This can be done manually, in an editor, or it can be done with automated tools.
For information on these tools, see "The Migration Plan" (p. 53).
Data Definitions
Your PDL file for RMS ISAM defined both logical objects (such as Elements) and physical storage
objects (such as Files, Records, Items and Indexes). The PDL for a relational application contains
only the logical objects and a pointer to the database. You also create a database SQL source file
containing the SQL equivalent to your File, Record, Item, and Index definitions.
The PDL Database statement often includes a database user ID and password within the Open
Name.
In addition to Usage, Element, and Database statements, the PDL may also contain Application
Security Class statements. PERMIT statements cannot be applied to relational data, but ASCs may
still be used in the USERS INCLUDE options of screens, runs, and reports.
Use QSHOW to generate the initial SQL from your dictionary:
QSHOW
> SET LANGUAGE SQL
> GENERATE DATABASE E
> $RENAME QSHOSQL.TXT QSHO_E.SQL
Normalization
relational databases achieve their benefits by working on the basis of normalized data.
Normalization is a design process removing redundancy in your data definitions. Thus a
migration to relational requires data structure changes while moving from PDL to SQL.
Ideally, you would make a full review of your record structures and implement a fully normalized
data model. At a minimum, it is necessary to remove all non-relational features from your data
definitions. This may result in additional data objects, but the resulting application programs are
easier to understand and maintain.
The following designs are not normalized:
• item substructures
• arrays (occurring or repeating items)
• item redefinitions
• multiple record layouts (used for coded records with Select values)
Item Substructures
You can normalize substructures in the following ways:
• Remove the highest level item and use lower levels only.
Unnormalized Normalized
Item MONTH-KEY Item INITIALS
Begin Structure Item MONTH
Item INITIALS
Item MONTH
End Structure
Unnormalized Normalized
Item TRANS-DATE Item TRANS_DATE
Begin Structure
Item YEAR
Item MONTH
Item DAY
End Structure
The first method is useful when the end user tends to enter the subitems individually; the second
approach is useful when you commonly work with the whole structure at a time (for example, a
date field).
If you choose the first method yet you need to access the higher-level item in your applications,
you can create a concatenated item in either the application (for example, a Define) or the
database (for example, a calculated column).
Similarly, if you choose the second method yet you need to access the lower-level item in your
applications, you can extract it in either the application (for example, a Define) or the database
(for example, a calculated column).
Arrays
Some relational databases support arrays, but they must be replaced with normalized structures
for PowerHouse 4GL applications. You can normalize arrays in the following ways:
• Define individual fields for each occurrence.
The first method is the simplest metadata change, but it is less practical if there are a large number
of occurrences, and it is not true normalization. It can result in many lines of application code. For
example, a screen cluster around one Field statement is replaced by multiple Field statements; a
procedural For loop is similarly replaced. This method might be appropriate for MONTH (12
values) but not for DAY_OF_MONTH (31 values).
The second method may be less efficient when reading, as the detail table holds one record for
each occurrence. However it can be more efficient in program processing logic, and require
simpler program changes. The I/O loss is often recovered by both the CPU savings and the easier
maintenance effort. As well, aggregate processing can be simpler and faster if you change your
logic to use SQL.
Item Redefinitions
You can normalize Redefines in the following ways:
• Remove one item and change the program logic to only use that one.
Unnormalized Normalized
Item USERID Item USERID
Item USERIDCHAR &
Redefines USERID
Unnormalized Normalized
Item USERID Item USERID
Item USERIDCHAR & Item USERIDCHAR
Redefines USERID
Which method you use depends on the reason for the original Redefine. The second method need
not require changes to your application code if you use relational database triggers or computed
fields to automatically populate one item with the value of the other item.
If you use a single large table, you can create views that report from specific subsets of that data.
Depending on the relational database and the Select statement within the view, you may also be
able to write to the table through the view.
If you choose to use separate tables, you may be able to report from all tables at once by creating
a database view that includes the data from all the tables.
Program changes are likely necessary after removing coded records. This includes changing or
removing Select options and "Set File Open n" statements.
Ordered Retrieval
Records in a relational table are not stored in a specific order (for example, chronological or by
unique index). Therefore, any programs that expect the data in a specific order but which have no
Sort statement need to be changed.
In the following examples, the new code is highlighted in bold:
QUICK
FILE EMPLOYEES IN TRACKING
ACCESS ORDERED &
VIA LAST_NAME USING LAST_NAME REQUEST LAST_NAME
QUIZ/QTP
ACCESS EMPLOYEES IN TRACKING
CHOOSE VIAINDEX LAST_NAME
For more information on ordering, see the Ordered, Orderby, and Viaindex clauses in the IBM
Cognos PowerHouse 4GL QDESIGN, QUIZ, and QTP Reference documents.
Null Values
Relational databases support the concept of null values by default. As this affects programming
logic and thus requires evaluation of all your program code, you may wish to disable null support
initially and investigate its benefits after your system has been fully migrated.
A null value is an unknown value. It indicates nothing, not zero or blank. Nulls model the real
world better than binary processing (True or False) does, because the real world often has missing
information.
For example, calculations containing null values evaluate to null. So Total = Supply + Labour
evaluates to null if either Supply or Labour is null. If the labour costs are unknown, the total cost
is unknown. (Compare this to binary logic, where Total = Supply if Labour has nothing in it,
because ’nothing’ is treated as a zero.)
Null support can cause conversion issues when loading your OpenVMS data into a relational
database. It can also cause logic errors in existing program code that is not expecting null
processing rules. For more information on null values in a PowerHouse context, see the IBM
Cognos PowerHouse 4GL PowerHouse Rules document, as well as the training courses, The
PowerHouse Relational Interface (Parts I and II).
Null value processing is disabled within PowerHouse 4GL by default: the PDL Database
statement has the default option of Null Values Not Allowed. This can be changed once the
migration is complete and you are ready to upgrade your programs to support nulls.
Miscellaneous Syntax
Relational tables cannot be opened with an access-type of Append, Clear, or Write (for example,
FILE x IN db OPEN APPEND). Valid types are Update (the default) and Read.
Relational tables can only be opened with an exclusivity of Share. We recommend you replace
exclusivity control with transaction control. For more information, see "The Next Step:
Relational Features" (p. 47).
The QDESIGN Lock and Unlock verbs, as well as the Lock option are generally not supported for
relational tables. The same is true for the QTP SET FILE [UN]LOCK and QUIZ SET [UN]LOCK
statements. Oracle has limited support for them, and they are ignored for other database systems.
In any case, for all relational databases, we recommend they be replaced with transaction control
statements. For more information, see "The Next Step: Relational Features" (p. 47).
The creation and maintenance of your relational database is handled by database tools rather than
PowerHouse 4GL. Thus, in QUTIL, the following syntax does not apply to relational tables, and
must be removed as follows:
CREATE|DELETE FILE x
Two PowerHouse 4GL options which behave differently in a relational application are Open
numbers (for example, FILE x Open 1) and the Close verb or option.
• Open numbers cause separate transactions to be created. We recommend they be replaced
with transaction control statements.
• The Close verb or option commits a transaction and then detaches from the database. We
recommend they be replaced with a Commit verb.
• For more information, see "The Next Step: Relational Features" (p. 47).
• stored procedures, functions defined within the database which can be explicitly called by
QUICK or QTP
For more information, see the IBM Cognos PowerHouse 4GL PowerHouse and Relational
Databases document and the training courses, The PowerHouse Relational Interface (Parts I and
II).
PDL
To migrate a Direct or Sequential PDL FILE statement, simply change the TYPE option (or
remove it completely, since it is optional):
OpenVMS: FILE x ORGANIZATION DIRECT|SEQUENTIAL TYPE RMS
UNIX, Linux: FILE x ORGANIZATION DIRECT|SEQUENTIAL TYPE UNIXIO
Windows: FILE x ORGANIZATION DIRECT|SEQUENTIAL TYPE DOS
The following FILE options do not apply to UNIXIO or DOS and must be removed:
CAPACITY
RECORD FORMAT
SUPERSEDE
Relative Files
UNIX, Linux, and Windows do not support relative files (which are like direct files that also allow
record deletion). To support the deletion capability, we recommend such files be migrated to an
indexed file system (C-ISAM on UNIX or DISAM on Linux and Windows).
This can be done with a simple index consisting of a one-segment sequence number.
On OpenVMS, use the following:
FILE x ORGANIZATION RELATIVE TYPE RMS
RECORD x
ITEM I1...
ITEM I2...
On UNIX, Linux, and Windows, use the following:
FILE x ORGANIZATION INDEXED TYPE CISAM|DISAM
RECORD x
ITEM I1...
ITEM I2...
ITEM SEQUENCE_NO
INDEX x1 UNIQUE
SEGMENT SEQUENCE_NO
To also populate the index value, you must modify any code that writes to the file. For example, it
could read the last record for its sequence number and then add that value plus one to the new
record. You may need to apply some locking in a concurrent-user environment.
Retrieval must be changed from a direct read (USING n) to an indexed retrieval (VIA segment
USING n).
PDL
The CAPACITY n FILE option does not apply to UNIXIO or DOS and must be removed.
Oracle Oracle
Sybase Sybase
We recommend the following migration paths (however a migration to any other relational
database would also be a viable option):
Study the documentation on your chosen relational database and compare it to your source
relational database to identify the changes you need to make to your SQL data definition file.
Common issues are the syntax structure, functions, and datatypes supported. Depending on your
data definition changes, this may also require modifications to your PowerHouse 4GL program
logic.
Datatype Mappings
PowerHouse 4GL makes few restrictions on datatype usage for keys and indexes. File systems, on
the other hand, are much more restrictive, so PowerHouse 4GL maps its datatypes to the best
match available when the file is generated using QUTIL. In some cases, a mapping that works well
in RMS ISAM may not work well with C-ISAM or DISAM.
If you are migrating from RMS ISAM to C-ISAM or DISAM, review your key and index datatypes
using the following table and adjust them where appropriate. If you create the files outside of
PowerHouse 4GL, ensure that the indexes you create are consistent with the PowerHouse 4GL
definitions.
Since PowerHouse 4GL does not generate relational databases using QUTIL, it makes no
assumptions about relational datatypes.
The following table compares the file system datatypes for each PowerHouse 4GL datatype:
G-FLOAT
5
not permitted --
INTERVAL
5
not permitted DOUBLETYPE
PACKED SIGNED
3
packed CHARTYPE
Moving Forward
"The Migration Plan" (p. 53) describes the 12-step plan to perform the migration. This identifies
everything from identifying training needs to editing data definitions.
At this stage, you have evaluated the choices for both your target platform and your target file
system(s). This chapter describes the twelve-step plan to actually perform the migration. This
covers everything from identifying training needs to editing data definitions, with an emphasis on
the physical migration activities in Step 6.
Step 2: Learn
Learn about your target platform and file system(s). If you will be using the Axiant 4GL migration
tools in step 6, learn about those as well.
This learning can be done by reading the appropriate documentation, discussing the issues with
knowledgeable co-workers, or taking training courses. The time and costs invested in education
will be recovered later by a smoother migration.
Relevant IBM courses include the following:
• Migrating Applications with Axiant 4GL
• The PowerHouse Relational Interface (Parts I and II)
• Axiant 4GL - Building Applications
• PowerHouse Web - Developing Applications
For information on these and other courses, see http://www.ibm.com/support.
You may have to create some new tables to make up for non-relational structures in RMS
ISAM files. You may also want to create new relational database objects (such as views and
triggers), which in turn affect your programs.
Use QTP to transfer data into portable subfiles. Also convert any data currently in permanent
subfiles to portable subfiles for transfer to the new platform. Use QTP instead of QUIZ because of
internal differences in generating the mini dictionaries (such as the way arrays are described).
QUIZ subfile contents are also based on the items in the REPORT statement, which has a
maximum record length of 256 characters.
When writing your data to portable subfiles, you do not usually have to code ITEM statements.
For example:
QTP:
ACCESS PAY [IN database]
SUBFILE PAYSF KEEP PORTABLE INCLUDE PAY
GO
Name changes applied during the data definition migration are automatically applied to
your programs. You can also customize any program changes for the new platform or file
system.
4. Export the data definition source files:
• Use the Generate PDL tool to create the PDL file for your target platform and file system,
automatically removing options specific to OpenVMS and its file systems.
• Use the Maintain Databases tool to create the SQL file if you are migrating to a relational
database.
You can now edit these files for further customization, if desired.
5. Export the component program source files:
• When you imported the OpenVMS program source files into Axiant 4GL, they were
converted into Axiant 4GL objects. Compiling the application with a UNIX, Linux, or
Windows Build Profile creates *.qks, *.qts, *.qzs and other source files for your platform,
automatically removing options specific to OpenVMS and its file systems. Programs for a
relational file system also have the IN database option added.
• You can now edit these files for further customization. (For example, QDESIGN
procedural code statements with syntax specific to OpenVMS are not automatically
edited, so this is a good time to make these changes.)
• Use the Build Profile tool to identify what you want to compile, along with any compile
options.
You can specify a remote compile directly across the network to your target UNIX,
Linux, or Windows server, or you can do a local compile on your PC and save the
resulting source files, to be sent to your target platform later (using a tool like FTP for
UNIX or Linux, or a network copy for Windows). The local compile approach allows
you to separate the compile and send processes. However you must remember to set the
Keep Temporary Files flag in your Build Profile.
Axiant 4GL includes a powerful Find Object tool for making global changes to programs while
they are still Axiant 4GL objects. However you may prefer to make your edits after generating the
source files, using a UNIX, Linux, or Windows text editor. This depends on your own comfort
level with the various tools.
For target file systems like Oracle and DB2, you may wish to disable the generation of primary
keys. Oracle and DB2 automatically create a unique index for each primary key, but they only
allow one index on the primary key and you likely have your own index defined. To avoid this
conflict in Step 7, clear the Generate: primary key check box in the Migration Profile during your
data definitions import.
For a target file system that is relational, Axiant 4GL also generates foreign keys when it detects a
table whose primary key is a column in another table. Foreign keys, similar to the LOOKUP ON
syntax in QDESIGN but evaluated at write time, are a useful component of referential integrity
within a relational database.
For a migration from non-relational to relational, the subfile dictionaries (*.psd) need to have all
hyphens replaced with underscores (except for Leading or Trailing minus signs). For more
information, see "4. Send Files to Your Target Platform" (p. 57).
Note: the ls command (‘ls *.psd‘) is placed within grave marks (‘), not quotation marks.
The grave key is located above the Tab key on most full sized keyboards. It is to the left of the
space bar on many laptops.
• On UNIX or Linux, type source replace_hyphens.txt to invoke the script. On Windows,
this can be done after installing a UNIX emulation toolkit (such as MKS).
Note: the ls command (‘ls *.psd‘) is placed within grave (‘) marks, not quotation marks.
The grave key is located above the Tab key on most full sized keyboards. It is to the left of the
space bar on many laptops.
• On UNIX and Linux, type source replace_hyphens.txt to invoke the script. On
Windows, this can be done after installing a UNIX emulation toolkit (such as MKS).
In Conclusion
The following are key decisions to make in planning your migration from OpenVMS:
• Target platform: UNIX, Linux, or Windows
• Target file systems: Relational, indexed, direct or sequential
• End-user UI: Terminal, Windows GUI (using Axiant 4GL), or Web Browser (using
PowerHouse Web)
• Migration method: using Axiant 4GL migration tools or using editors and UNIX or Linux
scripts
• Migration timing: what do you move and in what sequence?
You now have the resources to make these decisions.
Numerics DO EXTERNAL
UNIX, 21
3GL locking
Windows, 35
UNIX, 22
DSC, See dictionary security classes
Windows, 35
dynamic function keys, 25, 39
A E
application security classes
education, 53
UNIX, 20
end-user UI
Windows, 33
choosing, 10, 11
arrays, 44
environment variables
ASC, See application security classes
UNIX, 14, 15
Windows, 27, 28
B execution time parameters, 38
backwards access UNIX, 20
UNIX, 25 Windows, 33
Windows, 38
Build Profile tool, 57 F
BuildExternal, 35
file extensions, 56, 59
PowerHouse on UNIX, 17
C PowerHouse on Windows, 30
case sensitivity UNIX, 14
Sybase, 43, 50 Windows, 27
UNIX, 13, 18 file names
Windows, 27 UNIX, 13
choosing Windows, 27
end-user UI, 10, 11 file systems, 41-51
file systems, 9, 10 choosing, 9, 10
platforms, 9 file transfer, 56, 57, 58
C-ISAM, 23, 25 file versioning, 16, 29
coded records, 45 files
command files, 14, 15, 28 access control, 16
Command Prompt window, 30, 34 renaming, 59
copyright, 2 Find Object tool, 57
courses, 53 first record, 48
cursors, 47 folders, Windows, 27
foreign keys, 57
FTP, 56, 57, 58
D function keys
datatype mappings, 41, 50 dynamic, 25
DCL command files, See command files
designated files
UNIX, 18
H
Windows, 31 hyphens, 43, 59
dictionary security classes
UNIX, 20 I
Windows, 33
IBM Cognos Axiant
direct files, 10, 48
Build Profile, 57
directory paths, UNIX, 13
Find Object, 57
DISAM, 37, 38
Migration Profile, 56
datatype mappings, 50
migration tools, 55
opens, 41
indexed P
See also RMS ISAM
parameters
subfiles, 23, 37
execution time, 38
to indexed, 41
Path variable
to relational, 42
UNIX, 16
Indexed files, See RMS ISAM files
Windows, 29
indexes, 46, 50, 57
paths in file names, Windows, 30
overlapping, 41
PDL differences
interrupt control
UNIX, 19, 25
UNIX, 18
Windows, 33, 38
Windows, 31
performance, 9, 10
items
periods in file names, 13
redefinitions, 45
PHD vs. PDL
substructures, 43
UNIX, 19
Windows, 32
K phfilename, 59
keys phlower, 59
dynamic function, 25 phparse, 59
foreign, 57 planning the migration, 53-61
primary, 46, 50, 57 platforms
choosing, 9
UNIX, 13-26
L Windows, 27-39
locking portable subfiles, 55, 58
3GL, 22, 35 POW command, OpenVMS, 18, 32
QKGO, 22, 36 PowerHouse differences
relational, 47 UNIX, 17
logical names Windows, 30
UNIX environment variables, 14, 15 primary keys, 46, 50, 57
Windows environment variables, 27, 28 printer options in QUIZ
UNIX, 24
M Windows, 38
mailbox files (MBX), 49
migrating Q
choices, 9-12 QDESIGN, See QUICK
from RMS files, 48 QKGO
from RMS ISAM, 41 UNIX, 19, 22, 25
overview, 5 Windows, 32, 35, 38
planning, 53-61 QSHOW
to indexed file systems, 48 differences, UNIX, 21
to relational, 42 differences, Windows, 34
tools (UNIX), 59 generating PDL, 55, 58
twelve step plan, 53 generating SQL, 42, 58
with Axiant tools, 55 QTP differences
without Axiant tools, 58 UNIX, 23, 25
Migration Profile, 56 Windows, 36, 39
multiple record layouts, 45 QUICK differences
multi-versioning, See file versioning UNIX, 21, 25
Windows, 34, 38
N QUIZ differences
normalization, 43 UNIX, 24, 26
null values, 46 Windows, 37, 39
QUTIL differences
UNIX, 21
O Windows, 34
operating system commands
UNIX, 14 R
Windows, 28
ordered retrieval, 46 RDB/VMS, 49
overview redefined items, 45
migration, 5
S W
scripts Windows, 27-39
UNIX, 59 file names, 27
Windows, 28 folders, 27
security, 16, 55 PDL differences, 33, 38
UNIX, 20 QKGO, 38
Windows, 29 QSHOW differences, 34
sequential files, 10, 48 QTP differences, 36, 39
SET JOB in QTP QUICK differences, 34, 38
UNIX, 23 QUIZ differences, 37, 39
Windows, 36 QUTIL differences, 34
SET JOB in QUIZ scripts, 28
UNIX, 24 scripts or batch files, 28
Windows, 37 subfiles, 31
SQL
commands, 47
cursors, 47
generating from Axiant, 57
generating from QSHOW, 42
subfiles
indexed, 23, 37
locations, 17
portable, 55, 58
UNIX, 17, 23, 24
Windows, 31, 37
substructures, 43
supported environments, 7
T
target platforms
UNIX, 13-26
Windows, 27-39
training, 53, 55
twelve step plan, 53
U
UICs, 16
underscores, 43, 59
UNIX, 13-26
case sensitivity, 13
directory paths, 13
file names, 13
migration tools, 59
PDL differences, 19, 25
PHD vs. PDL, 19
platform differences, 13
QKGO, 25
QSHOW differences, 21
QTP differences, 23, 25
QUICK differences, 21, 25