Running R:BASE 4.5 Plus Under Microsoft Windows 3.1
This file is designed to help you successfully run R:BASE 4.5 Plus under
Windows 3.1.
286 or 386
R:BASE 4.5 Plus comes as a "dual installation" product. You can install 
both a 286 version and a 386/486 version. The designation does not refer 
to machine type rather to memory usage.
The 286 or 16 bit version of R:BASE 4.5 Plus will run on a 286 machine or 
on a 386/486 machine. It runs in what is called real mode in conventional 
memory -- the first 640K of memory on your machine. It uses additional memory 
for what is called code swapping. All the actual processing of data occurs in
conventional memory. The 286 version uses up to 2Mb of additional memory for
code swapping, memory above 1Mb on your machine. That memory can be either
expanded memory or extended memory. The 286 version operates best when the
amount of free conventional memory (largest executable program size) is
The 386/486 or 32 bit version of R:BASE 4.5 Plus will not run on a 286 machine.
requires capabilities that are available only in the 386 and higher processor.
It runs in what is called protected mode in extended memory -- memory above
1Mb on your machine. The processing of data occurs completely in extended
memory. Conventional memory, memory below 640K, is not used for processing. 
The 386/486 version requires 2.5Mb of this additional, extended, memory. 
This means your machine must have a minimum of 4Mb total memory. If you do 
not have this much available extended (or expanded) memory and cannot make 
this much available, you cannot run the 386/486 version, but you can run 
the 286 version.
Here's how the areas of memory are laid out in your machine
                  |      Extended memory, usually added in increments
                  |      of 2 or 4Mb. R:BASE 4.5 Plus 386/486 version requires
                  |      at least 2.5Mb of available memory in this area.
        __________|___ 1Mb
                  |      384K of upper memory used for system resources
                  |      and for loading software high.
        __________|___ 640K
                  |      Conventional memory. R:BASE 4.5 Plus 286 version
                  |      requires at leaset 480K of available memory
                  |      in this area.
        __________|___ 0 bytes
At installation time, you select to install either the 286 version, or the 
386/486 version, or both. Both versions have the exact same feature set 
and can be used on the same databases running the same applications. The 
difference in operation lies in memory use. Many operations in R:BASE are 
limited by available memory. The 286 version typically has less memory 
available to R:BASE which can affect the size of the database (number of 
tables and columns, NOT number of rows) and application that can be used.
Both the 286/16 bit version and 386/32 bit version will run under Windows 3.1
as a DOS application.
Memory Management, Windows and R:BASE 4.5 Plus
There are both extended memory managers (HIMEM.SYS) and expanded
memory managers (QEMM386, 386MAX, EMM386). Most expanded memory
managers either map the extended memory as expanded or also operate as an
extended memory manager. The advantage that they have is they offer the
capability to load programs "high" -- in the memory on your machine between
640K and 1Mb. Loading programs such as network drivers, mouse drivers and
other TSR's high frees up conventional memory. It increases the amount of
available memory under 640K. This is particularly useful when running the
286 version of R:BASE 4.5 Plus or other DOS programs.
R:BASE 4.5 Plus runs under Windows with HIMEM.SYS, or you may choose to use
EMM386 (from Microsoft), QEMM386 (from Quarterdeck), 386MAX/BlueMAX 
(from Qualitas) or another memory manager. Microrim does not recommend any 
particular memory manager. However, it is suggested that you supply the 
NOEMS parameter (or the appropriate equivalent) to prohibit an expanded 
memory manager from attempting to manage or access memory above 1Mb. Most 
DOS applications, such as R:BASE, that know how to utilize memory above 1Mb 
know how to do it themselves, therefore, the memory manager becomes a "middle 
man" that may interfere more than help.
The DOS Extender used by R:BASE (DOS4GW) is both VCPI (Virtual Control
Program Interface) and DPMI (DOS Protected Mode Interface) compliant. You
may find less conflicts if you avoid EMM386. EMM386 is not VCPI or DPMI
compliant and Watcom and Rational Systems have both reported intermittent
problems when using EMM386 with the DOS Extender. The problems occur
when the memory manager is used to allocate expanded memory. Using the
NOEMS parameter usually resolves any problems. If using EMM386, the line
in your CONFIG.SYS file should look like this:
Windows requires HIMEM.SYS or a third party memory manager such as
QEMM386 or 386MAX. When DOS applications run, Windows immediately
allocates 1Mb of memory to run DOS and then any additional memory the
application needs in order to run. Windows can use disk space as virtual
memory through swapping. You see the amount of "memory" (actual memory 
plus virtual memory) Windows thinks is available by selecting Help
from the Program Manager main menu and then About Program Manager.
Because Windows can use disk space, sometimes you'll see a number much
larger than the actual amount of memory installed in the machine.
For additional information on memory refer to your Windows or DOS
documentation. Both QEMM386 and 386MAX also discuss memory management
in their documentation. Most third party books on Windows or DOS will also
discuss memory usage. See your Windows documentation for information on
virtual memory and swap files. A permanent swap file increases Windows 
performance as well as assisting in running R:BASE under Windows.
Running R:BASE 4.5 Plus 286 version under Windows 3.1
As mentioned above, the 286 version can be used on a 286 machine or on a
386/486 machine. It runs very well under Windows 3.1 on all types of 
machines. It runs in conventional memory, the first 640K of memory. Where 
the Windows environment is required, the 286 version is an excellent option. 
Performance will obviously not be as quick as the 386/486 version, but in 
the interactive Windows environment, most users find it completely acceptable. 
The 286 version of R:BASE 4.5 Plus works well under Windows for all but the 
extremely large applications where simply not enough memory can be made 
available. The 286 version is limited to processing in conventional memory, 
the first 640K or memory on the computer. Adding more memory will not 
increase the amount of memory available to the 286 version.
The 16 bit version of R:BASE 4.5 Plus may be run simply by creating a new 
program item for a Windows 3.1 desktop and naming the RBASE.EXE in the 
"Program Properties" dialog box. This option requires the R:BASE 4.5 Plus 
program files directory to be specified on the PATH statement in the 
AUTOEXEC.BAT file. Or, use a PIF file to run the program. Use the 
RBASE286.PIF that is installed in the R:BASE directory or make your own.
Make sure that the memory requirements in the PIF file reflects the memory
manager you are using. If you are using an expanded memory manager, allocate
memory on the EMS line. For extended memory allocate the memory on the
XMS line. In either case, the minimum is 0, the maximum would be 2048. For
conventional memory, you need to specify a minimum requirement of at least
420K (yes, our documented minimum is 480K, but sometimes, under Windows,
you need to specify a smaller number).
If you are experiencing difficulties running the 386/486 version of 
R:BASE 4.5 Plus under Windows 3.1, use the 286 version of R:BASE 4.5 Plus. 
Refer to the file MEMORY.TXT (Document 750) for information on using the RTVMCO
environment variable to increase the amount of memory available to the 
286 version.
Running R:BASE 4.5 Plus 386/286 version under Windows 3.1
The 386/486 version of R:BASE 4.5 Plus delivers overall better performance 
due to expanded CPU utilization. This is done through what is known as a DOS
extender which allows R:BASE to run in extended memory, memory above 1Mb,
rather than in conventional memory. R:BASE 4.5 Plus uses a DOS extender 
program, DOS4GW.EXE, provided by Rational Systems, Inc. The DOS extender 
does the actual work of managing the extended memory.
R:BASE 4.5 Plus 386/486 version uses version 1.9 of the DOS extender 
(DOS4GW.EXE). This version has been improved to be better "behaved" in 
the Windows environment. Not all systems work better with this version, 
however. An earlier version of the DOS extender, DOS4GW version 1.8, is 
available on the Microrim Bulletin Board, 206-649-9836, or on the Microrim
Forum on CompuServe. The file is named DOS4GW.18 or D4GW18.ZIP. This version 
can be downloaded and renamed to DOS4GW.EXE and used with R:BASE 4.5 Plus 
with no ill effects to R:BASE operations. Version 1.8 was used with R:BASE 
4.0a. R:BASE 4.5 also used version 1.9. A different version of the DOS 
extender may work better depending on other factors on your machine -- 
memory manager, TSR's, network drivers, BIOS etc. If you have trouble with 
version 1.9, you can try version 1.8; it may work better for you.
Several conditions must be checked when running the 386/486 version of
R:BASE 4.5 Plus under Windows 3.1.
1. You must have sufficient memory (either actual or virtual). As a rough
estimate, you need approximately 5.5Mb available memory per the HELP /
ABOUT dialog box from Windows 3.1 Program Manager main menu. We
recommend that the machine have a minimum of 8Mb of memory installed to
provide the necessary 5.5Mb free. With less memory installed on your machine,
you will need more virtual memory (disk space) available. With less memory,
you may want to run the 286 version.
2. You should use the DOS4GW.EXE version 1.9 (shipped with R:BASE 4.5 Plus).
3. If your computer does not have a math co-processor, you MUST modify your
Windows SYSTEM.INI file to include a device driver statement in the [386Enh]
(enhanced) section as follows:
Specify the actual location for your WEMU387.386 files. You may not know if
your machine has a math co-processor. Most 486-33 and higher machines come
with a math co-processor installed. Most 386 and 486-25 machines do not have a
math co-processor unless one was purchased and installed separately.
To tell if you need to add this line, start R:BASE under Windows. From the R>
prompt, do a SHOW VAR command. If #PI displays as 0.0 instead of
3.14159265358979 you need to add this driver. Another check is to do a SHOW
command. If TOLERANCE displays as -NAN instead of the default of 0. you
need to add this driver.
The file, WEMU387.386, is a device driver from WATCOM Systems, Inc., and is
copyrighted and supported by WATCOM.
4. If want to run R:BASE in a window instead of full screen, then you must 
either use a PIF file and check the 'windowed' box, or you just press 
Alt-Enter once R:BASE is loaded to tell Windows to reduce the full screen 
to a window. However, DO NOT display the R:BASE signon screen in a window 
or you will likely hang your Windows session. Suppress the signon screen 
by using the -R startup parameter. Put -R in the command line parameters 
field of your PIF screen or include it on the command line when you start 
An icon is included R:BASE 4.5 Plus. It is installed with the R:BASE program 
files and is named RBASE45.ICO.
As with the 286 version, the 386/486 version of R:BASE 4.5 Plus can be run 
using a PIF file or just creating a new program item. R:BASE 4.5 Plus 
includes a sample PIF file for the 386/486 version, RBASE386.PIF.
Multiple sessions
You may be able to run multiple sessions (windows) of R:BASE under Windows
simultaneously, depending upon your machine type and the amount of available
memory. If you choose to run multiple sessions of R:BASE, keep in mind two
important facts:
1. The more copies you run, the slower they will all perform.
2. If you open more than one session of R:BASE, be aware that you cannot
connect to the same local database in the multiple windows. You can connect
multiple sessions to the same database located on a file server. If you 
attempt to have two or more Windows sessions connect to the same local 
database at the same time, database corruption can occur. This same caveat 
applies to any programs running under Windows that open R:BASE databases -- 
R:BASE, Runtime, Crystal Reports for R:BASE, DataPublisher or even a Visual 
Basic program using the SQL Engine. If any of these two programs has a local
database open at the same time as another one, the database can be corrupted.
Out of Dynamic Space Error
You may receive an "Out of Dynamic Space" error when printing reports with
break points or executing a command with an ORDER BY clause. By default,
R:BASE allocates 128K of memory for sorting. You can further limit the amount 
of memory R:BASE will allocate for sorting by using the SET SORT MAX option.
SET SORT MAX specifies a maximum amount of memory, in K, to allocate for
sorting. A good number to use is 64; for example, 
       R> SET SORT MAX 64
Experiment to find the best setting for your application. This setting will 
apply everywhere that sorts are done.
The SET SORT MAX 64 command must be typed at the R> prompt, included in 
an RBASE.DAT file (or any named R:BASE startup file), or in the application
file. It cannot be set through the RBASE.CFG file.
Disk Caching
Disk cache programs are used to improve disk access performance. Data is read
from the disk into memory, then the next time it is accessed it is read from
memory not disk. Because of Windows use of swap files, a disk cache improves
Windows performance.
Windows typically installs and uses a disk cache program named SMARTDRV.
When running a disk cache program with Windows and R:BASE 4.5 Plus, be sure to
set the cache up in extended memory, not expanded memory. SMARTDRV uses
extended memory by default.
Usually the default SMARTDRV parameters are fine. However, if your machine
has less than 8Mb of total memory installed, you may not have enough memory
remaining to run R:BASE effectively after the cache is installed. By default,
SMARTDRV allocates as large a cache as possible to a maximum size of 2048
(2Mb). You may need to adjust the size of the cache to get R:BASE 4.5 Plus 
386/486 version to work well under Windows.
Refer to your Windows and DOS documentation for more information about
SMARTDRV. If you are using another disk cache program, refer to its
documentation for parameters regarding the size of the cache and how to 
specify that it uses extended memory.
If R:BASE 4.5 Plus 386/486 doesn't run under Windows 3.1
When there are problems with the memory management and interaction
between R:BASE 4.5 Plus and Windows 3.1, you may get a Windows error message,
your machine may hang or you may be exited from R:BASE with a protection
violation (resembling a hex dump of numbers all over your screen).
Some things you can try to resolve the problem:
1. Start an MS-DOS session under Windows - Seelect MS-DOS Prompt from the 
Main program group. Change to the directory where the R:BASE program
files are located, for example, C:\RBFILES. Start R:BASE with the command
RBASE -R. If R:BASE starts fine here, the problem may lie with PIF file 
2. Try these alternative PIF file settings.
 Memory Required    -1       Memory Desired         -1
 EMS Required        0       EMS Limit               0
 XMS Required      1024      XMS Desired           4096
Specify "FULL SCREEN" rather than "WINDOW".
3. Try using the -Z or -K startup options. Use the -Z to include more
conventional memory. Use the -K to allocate a larger initial buffer size. 
Refer to the imformation abotu startup options later in this file.
4. Set up a permanent swap file and/or increase the swap file size to at 
least 10Mb. This helps not only R:BASE operations but all other Windows
operations as well. Refer to the Windows documentation or on-line help for
information on increasing the swap file size. Select "32 bit disk access" if
5. Try running Windows in standard mode. This suggestion is from Microsoft
Product Support Services. According to them this will not adversely affect
6. Try using SMARTDRV.SYS instead of SMARTDRV.EXE. Or try SMARTDRV.EXE 
instead of SMARTDRV.SYS. SMARTDRV.SYS is supplied with DOS 5.0 or 6.0, 
SMARTDRV.EXE comes with Windows. SMARTDRV.EXE is loaded through the 
AUTOEXEC.BAT file, SMARTDRV.SYS is loaded through the CONFIG.SYS file. 
Refer to the Windows and DOS documentation for more information.
7. Verify there is no conflict with other software. Remove all TSR's and 
other drivers. Run with an AUTOEXEC.BAT that has PATH and PROMPT commands
only and a CONFIG.SYS file that has FILES and BUFFERS statements and
8. Try it on another machine.
9. Add more memory to your machine, particularly if it has less than 8Mb 
total memory installed.
10. Try a different version of the DOS extender, DOS4GW.EXE. Try this
particularly if you were successfully running R:BASE 4.0 or 4.0A under
11. Run the 286 version of R:BASE 4.5 Plus.
12. Review the file MEMORY.TXT (Document 750) for memory management alternative
There are combinations of machines, memory managers, and R:BASE 386/486
applications which will not run reliably under Windows. We are continuing to
look into the problem. Unfortunately, there aren't any known hard and fast 
rules on what combinations work and what combinations don't.
Additional Command Line Options
The -K Command Line Option
The value of K in this command line option is the number of 1024 byte blocks
(1K for each block) which are allocated by R:BASE when memory is needed
internally for its operations. The default value for K is 128, so memory is
allocated in chunks of 128,000 bytes. If you change this value to 1000, then
memory will be allocated in chunks of approximately 1Mb. This means that
R:BASE will initially grab 1 MB of extended RAM for work space, and may
never need to request additional RAM from Windows. This may help resolve
locking problems within Windows 3.1.
The -Z Command Line Switch
The 32 bit version of R:BASE 4.5 Plus executes in extended memory. By 
default, 200K of conventional memory is revserved for running other
programs with the ZIP command; the remaining conventional memory is used
for processing. 
However, you can tell R:BASE to allocate and use more or less conventional 
memory if necessary. Use the -Z option to reserve up NNN bytes of conventional 
memory (for functions such as ZIPing to programs). Conventional memory not 
reserved can be used for processing. R:BASE automatically allocates memory 
first in the extended area, then proceeds to the conventional memory if needed.
It will not, however, allocate any reserved memory.
For example, to tell R:BASE to reserve 250K of conventional memory during
processing, use the -Z switch on the R:BASE command line as follows:
       C> RBASE -Z250
This forces R:BASE to reserve 250KB of conventional memory for non-R:BASE
use (for example, to be used by a DOS application which you may ZIP to).
To have R:BASE use all available conventional memory, use -Z0. This tells
R:BASE to not reserve memory for other programs. While you cannot then use
the ZIP command, you can use the ZIP RETURN or ZIP ROLLOUT commands to
execute other programs. 
This switch has no effect for the 16-bit (286) version.
Microrim and R:BASE are registered trademarks of Microrim, Inc.
WEMU387.386 (c) 1991-1992, WATCOM Systems, Inc.
DOS4GW.EXE (c) 1991-1992, Rational Systems, Inc.
Windows is a trademark, and Microsoft and MS-DOS are registered trademarks of
Microsoft Corporation.
Qualitas and 386MAX and BlueMAX are registered trademarks of Qualitas, Inc.
QEMM386 is a trademark of Quarterdeck Office Systems, Inc.