==========================================================================
                   SUPERBASE 4 VERSION 1.3 June 25, 1991
==========================================================================
This document contains information which could not be included in
the User Guide.

                        ===================
                        GENERAL INFORMATION
                        ===================
TUTORIAL
--------
The Superbase tutorial in Chapter 33, Volume 1 of the User Guide
should be done in the IDEAS sub-directory of the Examples disk. IDEAS
contains the ACCOUNTS.CSV file, which is required for the tutorial.

The CLIENTS.SBV form referred to in Volume 1, page 1-18, is located
in the TRADING sub-directory of the supplied examples. The actual example
is different from the one shown in the illustration on page 1-18.

IMAGE PRINT METHOD
------------------
You can define the default image printing method that Superbase and 
the Form Designer use for images by specifying a parameter in the 
WIN.INI file. A printing method specified as part of filename in an 
external file field overrides this setting.

In the [Superbase] section of WIN.INI, add the following 
parameter:

ImagePrint=<option>

where <option> is one of the following:

     c    Color print
     e    Monochrome with error-distributed dither
     m    Monochrome with ordered dither
     h    Monochrome with half-toning

If the ImagePrint parameter is missing or blank or invalid, the system 
attempts to use the printer's own capability for selecting the best 
print method. If the printer lacks such a capability, the image is 
printed using half-toning provided the printer is capable of at least 
200 dots per inch, or ordered dither if it is not.

EXTERNAL FILE DISPLAY OPTION
----------------------------
The suffix option for loading images at full 24 bit color resolution is 
'f'. For example, entering "eagle.pcx,f" as the name of an external 
image file will cause the image to be loaded using this method.

SUPERBASE INTERNAL BUFFERS
--------------------------
The maximum number of buffers has been raised from 99 (approximately 
50K) to 999 (approximately 500K). This will allow greatly improved 
performance for many operations such as indexing and importing data. 
However, searches that involve sequential scanning of database files, 
such as unindexed queries, may perform more slowly if the number of 
buffers is very high.

It is advisable to experiment to find the optimum setting for different
types of operation.

The default number of buffers as defined in Set System Options has been
increased to 30.

Note that these internal buffers have no relationship to other system
settings, such as BUFFERS= in CONFIG.SYS.

LABELS
------
The Label Definition dialog allows you to enter label dimensions in 
inches or centimeters. Radio button controls enable you to switch 
units of measurement. 

Superbase versions 1.21 and earlier store label dimensions in row and 
column units. Version 1.3 translates the parameters of existing 
SBB label definition files into hundredths of an inch if the 
label width is less than 100. This means that the minimum label width
is one inch. You should save all SBB files created prior to version 1.3
under version 1.3 to change their parameters to hundredths of an inch.
Superbase uses the same rule when parsing the DML LABELS command. 

The SET LABELS REQUEST command, which displays the standard label 
definition dialog, requires a subsequent LABELS command after the user
clicks OK to begin actual output.

QUERY OPTIMIZER AND DATE AND TIME LITERALS
------------------------------------------
The query optimizer does not support the use of date or time string 
literals with date and time fields. An expression such as:

	Datefield.MYFILE >= "1 1 91" 

will cause a data type mismatch error, because the date field actually
holds a number. Such expressions must be changed so that both items 
being compared have a numeric type. This can be done by using functions,
for example:

	Datefield.MYFILE >= DAYS("1 1 91")

The string literal comparison is still supported provided the query
optimizer is not enabled.

FILTER OPTIMIZATION
-------------------
The way in which basic filter optimization works in Version 1.3 means 
that more attention must be paid to the use of the following 
operators with strings.


        >       Greater than
        <       Less than
        >=      Greater than or equal to
        >=      Less than or equal to

You should change certain filter expressions to use the LIKE operator.

Old:
LEFT$(fieldname,1) >= "g" AND LEFT$(fieldname,1) <= "k"

New:
fieldname LIKE  "[g-k]*" 

Since Version 1.3 optimizes filters that use certain forms of the LIKE 
pattern-matching syntax, you can obtain fast performance as well as 
case insensitivity by substituting LIKE for the relational operators.

NOT/AND/OR
----------
In queries, care must be taken when using these operators with numeric
expressions not equal to 0 or -1. For example, when using AND you 
intuitively expect that both operands must be true for the whole 
expression to be true; however, Superbase treats AND as a bitwise 
operator if both operands are integer or long type, but not as bitwise 
if either operand is real type.

USING ENTER IN PUSHBUTTON COMMANDS
----------------------------------
You may use the ENTER command in a pushbutton command line. However, 
if the command line contains more than one command, ENTER will always 
be executed after the other commands, even if it precedes them in the 
line. Multiple ENTER commands are not allowed, and the ENTER keyword may 
not be used in an Auto Execution command.

LAUNCHING SUPERBASE
-------------------
If an SBV file is used to launch Superbase 4, the START.SBP program is 
executed. However, if an SBF file is used to launch Superbase 4, 
START.SBP is not executed.

MAIL MERGE
----------
Mail merge does not allow long text data (i.e. longer than 254
characters) to be used with fixed length document fields.

FILE REMOVE: LAN VERSION
------------------------
The File Remove menu command normally deletes the SBF, SBD, and all 
index files that share the same root filename. However, in the LAN 
version of Superbase users may lock text or other types of Superbase 
file with the same root filename. The locking for such a file is 
controlled in the same Superbase lock file (SB! extension) that 
controls the locking of the data file. Consequently, File Remove only 
removes an SB! file if it is not being used for locking any other file. 

COPYING .SB! FILES
------------------
Never copy a Superbase .SB! lock file. Each lock file points to a 
specific location in its SUPERBAS.NET network control file, so if 
more than one copy of a data file with an associated SB! file is 
opened then all the SB! files will point to the same SUPERBAS.NET 
location, and record locking will not be properly controlled.

SET ERROR OFF
-------------
Error 47, Data Too Long For Field, is the only error that does not 
generate an error condition when it occurs following SET ERROR OFF. 
Usually, this error only occurs during an import operation, and it is 
preferable to allow Superbase simply to truncate the data that is too 
long rather than to interrupt the import.

SET PG
------
The parameter string for SET PG always requires the period or 
full stop decimal point even if your Windows international setting 
specifies the comma decimal point.

WAIT MOUSE
----------
This command does not interpret the act of editing a field, which 
involves clicking the mouse, as a triggering event. Consequently, 
clicking on form check boxes or radio buttons that are attached to 
fields will not cause processing to continue. Form check boxes or 
radio buttons that are attached to variables rather than fields are 
not subject to this restriction.

MOUSE
-----
The MOUSE command has been modified so that the mouse location 
co-ordinates are always relative to the active window rather than to the 
screen. FN SYS (9) and FN SYS (10) may be used to return the X and Y co-
ordinates of the Superbase window if these are required.

The MOUSE parameter that returns mouse status has also been modified.
When a dragging action is ended by the user releasing the mouse button,
the value returned by MOUSE reverts from 3 to 1.

LIST BOXES
----------
Windows limits the data content of a list box to 64K, so some Superbase 
dialogs with many potential entries, such as REQUEST 25 and File Modify 
dialogs, may not show all of them. 

REQUEST IN VALIDATION FORMULAS
------------------------------
Field validation formulas may use any form of the REQUEST command that 
returns a value into the field to which the formula is attached. This 
includes REQUEST 4 through REQUEST 20, and REQUEST 23 through REQUEST 
25.

ADD WITH INDEXED FIELDS
-----------------------
Version 1.3 extends the DML ADD command to allow you to add fields to 
an existing file definition. If you include IXD or IXU in the field 
definition string in order to specify an indexed field, Superbase does 
not generate an error even though there is no index. However, you must 
create an index for the new field before saving the file definition 
and closing the file, or Superbase will be unable to re-open the 
file.

LOOKUP
------
A virtual field with a calculation formula involving a LOOKUP
to a second file causes the current record in the second file to
change whenever a record is read in the first file.

Superbase's query facilities, Process Query and the DML SELECT command,
do not support virtual fields that use LOOKUP when the two files related
in this way are actually involved in the query.

DIALOGS
-------
When entering text into an edit box (object type 6) in a DML-defined 
dialog, you may use the CTRL+ENTER key combination to embed a 
carriage return in the text. This appears as a carriage return if the 
text is assigned to a Superbase long text field.

List boxes and combo boxes use string arrays to hold their contents. 
If you include a null string ("") in the array, the displayed list 
will terminate at that point. If you need to display a blank element 
in the list, use a space character.

IDENTIFYING FORM OBJECT CO-ORDINATES
------------------------------------
If you plan to use DML to modify objects on forms that you create with 
the Form Designer, you will need an easy way of identifying the co-
ordinates of each object. The following procedure allows you to do 
this:

1. In the Form Designer, select the desired object.
2. Locate the mouse pointer at the top left-hand corner of the 
selection rectangle. The Cross-hairs tool will help you to do this 
acccurately.
3. Note down the co-ordinates shown at the right of the toolbox. These 
will be in inches or centimeters depending on the setting in the 
Rulers and Grids dialog.
4. In your DML program, ensure that the command SET FORM USING has 
been executed to set the units of measurement to correspond to the 
units of measurement in the Form Designer.
5. Whenever you need to locate a form object, give the co-ordinates 
you noted down in step 3 above.

SET FORM USING
--------------
This command specifies the co-ordinate system that will be used by the 
FORM ADD, FORM REMOVE, and FORM MODIFY commands. If a value from 0 to 
3 is given, then when using the FORM MODIFY and FORM REMOVE commands 
the co-ordinates given will find the last object added whose bounding 
rectangle contains those co-ordinates.

If a value from 4 to 7 is given, then the object found will be the last 
object added whose X,Y co-ordinates match exactly the values given.

The full parameters are:

	RECTANGLE   EXACT    UNITS OF MEASUREMENT
	    0         4            MM
	    1         5            Inches
	    2         6            Pixels
	    3         7            100ths inch

FOREIGN CHARACTERS
------------------
Some characters in languages such as Norwegian and Danish cannot be 
displayed or stored properly unless certain Windows 3 system 
parameters are set correctly.

In the [boot] section of SYSTEM.INI:
1.  The 'oemfonts.fon=' item must be set to a filename of the form 
'vgaNNN.fon', where NNN corresponds to the code page for the language 
required. 
2.  The 'oemansi.bin=' item must be set to a filename of the form 
'exlatNNN.bin', where NNN corresponds to the code page for the 
language required.

For example, exlat865.bin is the file required for oemansi.bin in 
Norway. Use the Windows 3 Notepad tool to edit SYSTEM.INI.

The files themselves are on Windows 3 disk 2, as is the EXPAND.EXE 
Windows extraction tool which is needed to expand them. EXPAND.EXE is 
described in the Windows 3 README.TXT file.

TEXT MARGINS
------------
The [Superbase] section of the WIN.INI includes a setting for the
default margins of Superbase text files and the margins of external
text files. For example, TextMargins=1,75,2,60 would specify:

     Default Left   1
     Default Right  75
     External Left  2
     External Right 60

DBASE FILES UNDER DML
---------------------
dBase files opened directly under DML must be indexed before you can
browse, using SELECT NEXT and SELECT PREVIOUS. To make this possible,
save a DBD file which identifies the dBase indexes.

IMPORTING DIF FILES
-------------------
The character set used by DIF files is assumed to be the IBM
character set, unless the ANSI conversion option has been selected
or the header of the DIF file has the title "Excel."

OUTPUT FORMAT PARAMETERS
------------------------
Three modifiers are available for the & formatting parameter to 
specify left, right or centered output of a field or variable.  

&[nn      Left aligns item within a column nn characters wide.
&|nn      Centers item within a column nn characters wide.
&]nn      Right aligns item within a column nn characters wide.

For example, to force a date to be left aligned in a column 20 
characters wide, use a command of the form:

                    ? &[20 datefield.FILENAME

Proportional Fonts are not supported with this feature.

The modifiers may also be set from within the Report Generator part of 
the Form Designer.  To specify the type of alignment required, select 
the item or items required and click the justification tool in the 
Toolbox to the left, vertical (centered) or right pointing arrow 
position.

DDE EXTENSION
-------------
A 'Superbase' topic is provided for use in DDE operations. Use the 
Superbase topic if no Superbase file is open or your application does 
not know which Superbase file it is using.

You can also REQUEST and POKE Superbase fields and variables using the 
Superbase topic. If you POKE data into fields while using the 
Superbase topic, the first filename encountered is used to set the 
topic file, i.e. the one into which data is stored after the POKE.

You can also perform a multi-file query using the Superbase topic 
instead of a filename topic, as long as the REQUEST includes a WHERE 
clause with a join between the files, which must be explicitly named 
in the filename extensions to each field. The data retrieved by such a 
query is stored on the clipboard as record rows with tab separated 
fields. In Microsoft Excel, for example, such data may easily be 
pasted into a worksheet.

DDE RESTRICTIONS
----------------
Note that Superbase does not currently support ADVISE on the system 
topic or variables.


                            ==============
                            DML EXTENSIONS
                            ==============
CHAIN
-----
The CHAIN command may use the APPEND keyword in the same way as LOAD.
CHAIN "myprog",APPEND will load MYPROG.SBP into memory, appending 
it to the end of the calling program.

This command acts like a normal CHAIN and preserves existing variables.
However, program execution resumes at the start of the calling program, 
so you must provide flow control statements at the beginning of your code
to direct execution to the appended module.

FN SYS
------
Additional FN SYS functions allow you to report the version number of all
Superbase system DLLs. The information is provided to assist support
engineers, and is not of direct concern to end users.

FN SYS (50) Version number of SBLOCK.DLL
FN SYS (51) Version number of SBIMAGE.DLL
FN SYS (52) Version number of SBDIALOG.DLL
FN SYS (60) Version number of SBSQLSVR.DLL
FN SYS (61) Version number of SBSQLBAS.DLL
FN SYS (62) Version number of SBSQLORA.DLL
FN SYS (63) Version number of SBSQLXDB.DLL

For FN SYS (50), the HIBYTE is the version number of the SUPERBAS.NET 
file.
For FN SYS (60) to FN SYS (63), the HIBYTE is the internal version number 
of Superbase's embedded SQL.

MENU
----
The MENU command allows you to specify a Windows standard menu item 
separator. The value 3 must be specified for the third numeric 
parameter:

	MENU 1,2,3

The second item in menu 1 will be a separator.

PRINT
-----
The SHOW keyword may be used in a PRINT statement to reduce the time 
taken to print images that appear on forms. SHOW should be inserted 
after the CURRENT/FILE and PAGE/ALL options.

SER
---
A SER calculation formula should use the name of the field to which it
is attached rather than the literal name of the file to which it refers.
Superbase is able to resolve fieldname references during Query to file
or Reorganize.

SET FORM
--------
The ROW keyword has been added. The full syntax is:

	SET FORM ON/OFF field/var [ROW nexpr] [,field/var [ROW nexpr]]...

Use the ROW expression to refer to a field or variable in a specific
transaction line. If you omit the ROW expression and refer to a field
or expression in a transaction line, all instances will be affected.
Array variables, however, may be referenced by subscript.

The FORM command must be used to refresh the display following SET 
FORM.

SET REQUEST HEADING
-------------------
(This command was introduced with Version 1.21 but was omitted from 
the Version 1.3 manual supplement.)
	Purpose
	-------
	Allows Superbase system dialogs to be displayed with a 
	custom title.

	Syntax
	------
	SET REQUEST HEADING strexpr

	Comments
	--------	
	This command affects all information and error messages, 
	the printing process dialog, the communications process 
	dialog, and REQUEST dialogs with a type number above 99. 
	The strexpr also appears in the title bars of the main, 
	text editor and program editor windows.

	Example
	-------
        	SET REQUEST HEADING "Garage Base"
        	REQUEST "Exit Application?","",129,a%

	Sets the dialog title bar so that the user does not realize 
	that the application is developed with Superbase.

UPDATE FORM ROW
---------------
UPDATE FORM ROW has been extended to allow the selective updating of 
transaction line data. The full syntax is:

	UPDATE FORM ROW rownumber [,field1][,field2]...

UPDATE FORM ROW copies record data into the transaction line. If you 
have changed any record data, for example by pre-assigning a value to a 
field, then all fields will be flagged as changed, which could 
trigger unwanted validation checks. The new syntax lets you specify 
which fields in the transaction line you wish to update.

                              ==============
                              ERROR MESSAGES
                              ==============
160 Application Busy
--------------------
Under DDE, Superbase's attempt to send a message to another 
application has received a 'busy' response.

161 Precision Error in Math Function
------------------------------------
A math function result may be inaccurate owing to floating point
limitations.

162 This form cannot be loaded as it requires a later version of the 
software
----------------------------------------------------------------------
-------
You have attempted to open a form created with a later version of the
Form Designer. Obtain an update from your supplier.

163 Reorganize Failed to Complete
---------------------------------
You have attempted to reorganize a file using the same name for the
destination file, and Superbase has detected that the number of
records in the new file is different. To avoid possible loss of data,
Superbase has aborted the Reorganize process, leaving the source file
intact. Reorganize to a different directory and/or filename.

164 Insufficient Disk Space
---------------------------
The operation attempted has failed due to lack of space on the target
disk.

165 Cannot Open Library
-----------------------
An attempt to REGISTER a dynamic link library function has failed
because Superbase could not open the specified library.

166 Invalid Argument to Function
--------------------------------
The argument specified in a REGISTER statement is not valid.

167 Cannot Find Function
------------------------
The function supplied in a REGISTER or CALL statement does not exist
in the specified library or has not been registered.

168 Function Already Defined
----------------------------
The specified dynamic link library function has already been defined
with REGISTER. Use REGISTER CLEAR to re-initialize before re-
registering the function.

169 Invalid Superbase library
-----------------------------
One of Superbase's DLL files is corrupt or out of date.

179 Invalid outer join syntax
-----------------------------
You have used an outer join operator without a field on the asterisked 
side, or an unsuitable operand in the outer join expression.

180 Too many outer joins
------------------------
You have used a file in more than one outer join expression.

181 Query optimization error
----------------------------
The query optimizer has detected a syntax error. Turn off the 
optimizer and re-run the query to identify the error.

182 Error from SQL system
-------------------------
The SQL database system to which you are connected has returned an 
error. The error number of the error is available in the global 
variable ERROR, and the error message is available in the global 
variable ERR$(0).

183 Invalid SQL connect command
-------------------------------
A SQL connect command has invalid syntax.

184 SQL command too long
------------------------
The maximum length of a DML embedded SQL command has been exceeded.

185 Not connected to SQL system
-------------------------------
You have executed a SQL command without having established a 
connection to a SQL database system.

186 No SQL command has been prepared
------------------------------------
You have executed a SQL fetch command without having executed a SQL 
prepare command.

187 Invalid context for INTO
----------------------------
You have used the DML SQL extension INTO either with a SQL command 
that does not allow it or in the wrong syntactical context.

188 Cannot find form object
---------------------------
The DML commands MODIFY FORM or REMOVE FORM have failed to locate an 
object upon which to act.

189 Query optimizer not enabled
-------------------------------
You have attempted to run a query containing an outer join expression 
prior to enabling the query optimizer with SET QUERY ON.

190 Dialog already exists
-------------------------
The DML command CREATE DIALOG has been used with a name of a dialog 
that has not been removed with REMOVE DIALOG.

191 Cannot find dialog
----------------------
The DML commands ADD DIALOG, DIALOG, and REMOVE DIALOG require that 
the dialog referred to has been created with CREATE DIALOG and has not 
yet been removed with REMOVE DIALOG.

192 Cannot create dialog
------------------------
System error.

193 Invalid SQL option
----------------------
The option specified in a SQL option command is not valid for the SQL 
database system to which you are connected.

194 Incompatible software version
---------------------------------
You have attempted to run a version of Superbase SQL Library that 
requires a more recent version of Superbase.

                           =================
                           USER GUIDE ERRATA
                           =================
Page numbers refer to the user guides for Superbase 4 Version 1.10, 
except where indicated.

Volume 1
========
Throughout
----------
References to Record Print, Process Print, and Utilities Printer should 
be disregarded. Instead see the File Print command.

Page      Erratum
----      -------
8-4       The figure $9.20 in the example should be $19.20.
16-2      Defining a Fields Line for Query to SB File.  The & Length 
          parameter may not be used to set a field's format in the 
          new file.

Volume 2
========
Chapter 17
----------
Page numbers for errata in the first and second editions of the 
manual are as follows. 
1st Ed.		2nd Ed.
17-37		17-38		CREATE
17-62		17-63		EXISTS
17-93		17-100		IMPORT
17-159-63	17-166-70	REQUEST
17-193		17-200		SET PG
17-202		17-210		STR$

CREATE. The third item under Syntax is incorrect. The keyword AND 
should be replaced with a comma.

Syntax should read as follows:
   CREATE FILE sbfilename, sbfilename FROM FILE sbfilename WHERE conditions   [;passwords]

EXISTS. The filename extension must be supplied.

FN. The significance of the type parameter in the financial functions FN 
fv, FN nper, FN pmt, FN pv, and FN rate is reversed. The correct 
significance is:
     0    Computes for end of month
     1    Computes for beginning of month

IMPORT. Example #8 should omit the final 'newdata'.

REQUEST. Maximum length of text strings and edit box is 72 characters, 
not 50.
REQUEST types 102 through 150: the message "Abort Retry Cancel" should 
read "Abort Retry Ignore".
REQUEST types 100-112 display an Information icon.
REQUEST types 139-151 display a Stop icon.

SET PG. The parameters refer to left, right, top and bottom margins in 
that order.

STR$. The number 6.667 in the Notes section should read 5.667.

Chapter 19 (Version 1.3 edition)
--------------------------------
Page 19-33 Example 'ERRNO = 36' should read 'ERRNO = 136'.

Chapter 20
----------
Page 20-4 DDE$ syntax should read:

	DDE$(strexpr1,strexpr2,strexpr3[,nexpr1[,nexpr2]])

Supplement (Version 1.3 edition)
================================
Page S-36. Note to Example 1. Change 'Process Remove' to 'File Remove'.

Page S-42. Example line 4. Change 'trow%' to 'trow%%'.

Page S-74. Comments. Change 'SET COPY ON' to 'SET COPY NEWLINE ON'.

Page S-101 Comments, paragraph 5, first sentence. Change 'Superbase 
Window' to 'dialog'.
==========================================================================
                           END OF README.TXT
==========================================================================
