Emulation support is provided by the Config_EMULATE file in the "config" subdirectory of the jBASE release directory. All text in the file is case insensitive.
Labels must be alpha-numeric, i.e. no periods, underlines, etc. If one label directly follows another then the label is synonym for the same emulation definition.
The emulation definition ends when another label or the end of file encountered.
Multiple emulation definitions can be defined on the same line with each definition delimited by a comma or a semicolon.
Emulation definitions can be interrupted by blank lines and can contain any amount of white space, i.e. one or more spaces or tab characters.
Emulation definitions can be declared 'on', 'yes' or 'true' to mean the emulation is enabled or similarly use the strings 'off', 'no' or 'false' to mean the emulation effect
is disabled.
To use a different set of emulation definitions from the default set, set the environment variable JBCEMULATE in your current
environment to the required emulation label. When the environment variable is not configured then the emulation definition defined by the default label is in effect. If the
default label is not present then the first label detected will be used for the default emulation.
Generally any emulation definitions which affect BASIC, (like the @(-n) codes), use the JBCEMULATE environment variable when the programs are
compiled, whereas the other definitions tend to be used at runtime, when the program is executed.
As of the jBASE 5.5.0 release, compile time and run time case insensitivity options have been introduced, see also jBASE CI Overview
Variable |
Description |
Set At: |
allow_bad_day_of_month = true|false |
If set, allows invalid date conversions like 31 Sep to convert to valid dates (1st Oct). |
Run Time |
allow_unassigned_assignment = true|false |
Suppress "UNASSIGNED VARIABLE" message where "X=Y" and Y has not been assigned. |
Run Time |
alternate_chain_exit = true|false |
If set then under certain circumstances drops an extra run level on returning from a CHAIN command.
This is an emulation of jBASE 3.4 behaviour. Current behaviour is believed to be preferable.
Only set this if necessary for backwards compatibility. |
Run Time |
alternative_oconv = true|false |
If set then for the "DD" and "DM" output conversions, single digit results are prefixed by zero. Default for Sequoia. |
Run Time |
breakon_l_suppresses_blank_line = true|false |
If set then "L" in a "BREAK-ON" clause means suppress the blank line before the data line.
The default is to skip the break line, i.e. only output a blank line. |
Run Time |
byexp_mv_dup_like_d3 = true|false |
If set, when using BY-EXP, reuse the first, and only, value in single valued attributes.
The default behaviour, i.e. with "byexp_mv_dup_like_d3" unset or false, is to assume a null value for the 2nd and subsequent values.
Currently, this option is not set under any emulation in the "Config_EMULATE" file supplied with the jBASE Installation. |
Run Time |
case_insensitive_file_ids = true|false |
If set, try and ignore the case of file names, default behaviour will be to open the first UPPER CASE version of the file name. |
Run Time |
case_insensitive_md = true|false |
If set, the MD does not care about case, everything should end up as UPCASE. |
Run Time |
case_insensitive_queries = true|false |
If set, verbs used in jQL queries and dictionaries ignore case. |
Run Time |
case_insensitive_runtime_strings = true|false |
If set, any jBASE functions which accept a VAR as a parameter will UPCASE it. |
Run Time |
compiler_case_insensitive_subroutines = true|false |
If set, all SUBROUTINE names are case insensitive. |
Compile Time |
compiler_case_insensitive_variables_keywords = true|false |
If set, the compiler ignores the case on variable names and keywords. [Not currently implemented] |
Compile Time |
chk_typeahead_on_inputminus = true|false |
If set then check for typeahead when INPUT x,-1 syntax is used. |
Run Time |
conv_mct_uv_compat = true|false |
Universe compatible capitalisation after non-alpha characters. |
Run Time |
conv_old_mct = true|false |
Capitalise character following non-alpha character, e.g. "-" (hyphen). |
Run Time |
dates_upper_case = yes|no |
If "yes" then date conversions (e.g. "DM" and "DW") force the text to uppercase format, e.g. "March"
is forced to "MARCH".
Without this option, the casing for dates is dependent upon the operating system. |
Run Time |
defer_header_output = true|false |
Set by default under Ultimate emulation.
Any Basic HEADER will be output at the next natural page break.
Normally the HEADER is issued immediately. The output of the HEADER can also be deferred, to the next natural page break, by prefixing the HEADER data with an Attribute Mark (@AM). |
Run Time |
dict_sub_call = true|false |
On some emulations, when calling a SUBROUTINE from a DICT item, a parameter will be passed to the SUBROUTINE which is the current item
-- if this is the case, set this to "true". |
Run Time |
dot_not_numeric = true|false |
Set to true for compatibility with systems that expect ".", "+" and "-" to be
treated as non-numeric characters. |
Run Time |
dup = name |
Duplicates the definition "name", where "name:" is a previously defined "label:", i.e. this "definition"
inherits the behaviour defined for "name:", "option" settings following a "dup" override the inherited behaviour for that "option". |
N/A |
enter_keeps_common_data = true|false |
Set if you want the ENTER statement to retain global common when "(I" option is used. |
Run time |
error_numbers_are_single_attribute = true|false |
If set, check that the first value is a number, if so use it as the error message, (i.e., return 401 instead of 401]QLSELNO) (Could be problematic). |
Run time |
ext_pattern_match = true|false |
For systems which use extended pattern matching. |
Compile Time |
format_defaults_no_decimals = true|false |
If set, a format mask that does not specify decimal places will not output any decimals. Default is to output all decimal places. |
Run time |
generic_pick = true|false |
The emulation will otherwise behave as if coming from a Pick environment. |
Compile Time1 |
generic_prime = true|false |
The emulation will otherwise behave as if coming from a Prime environment. |
Compile Time1 |
generic_reality = true|false |
The emulation will otherwise behave as if coming from a Reality Operating System environment. |
Compile Time1 |
generic_universe = true|false |
The emulation will otherwise behave as if coming from a Universe system. |
Compile Time1 |
generic_unidata |
The emulation will otherwise behave as if coming from a Unidata environment. |
Compile Time1 |
header_with_s = yes|no |
For systems (Sequoia) S-types with null "header" WILL use the default column heading. |
Run Time |
hush_input_and_output = true|false |
If set then control both input and output on HUSH. |
Run Time1 |
iconv_nonnumeric_return_null = true|false |
If true then ICONV will return null instead of the original value when that value is non-numeric and numeric is expected. |
Run Time |
insert_default_zero_to_one = true|false |
If set, treat a param value of zero as one for INSERT function. |
Run Time |
invert_F_correl = yes|no |
Set this for systems (Reality) where the F correlative operates on the top stack elements in the reverse order to that expected for certain operators |
Run Time |
itype_trans_replace_delim = true|false |
Set to replace delimiters with spaces in the TRANS() function ( ITYPES only ). |
Run Time |
itype_unquoted_numeric_literal = true|false |
Set for systems (Universe/Unidata ) where the 3rd and 4th parameters of the 'FIELD'' function can be specified as an unquoted numeric.
The unquoted numeric will be treated as a numeric literal in these cases, rather than an attribute reference. |
Run Time |
jbase_field = yes|no |
For systems (jBASE and Prime), FIELD function will use the entire delimiter not just the first character. |
Run Time |
jpqn_replace_semicolon = true|false |
Set by default under Ultimate emulation.
When moving data from the Input buffer to the Primary Output buffer using the A command in PQN Procs, any semicolons are replaced with specified delimiter, e.g. : A' changes abc;def;xyz to abc"def"xyz. |
Run Time |
jql_A_substring_literal |
For systems (as yet unknown) which assume unquoted numerics (inside substring extraction) should be treated as Numeric literals (NOT attribute references as expected by default). |
Run Time |
jql_acalc_int_only |
Set for systems (Reality, R83, Universe) where integer only arithmetic is performed in calculations within "A;" correlatives/conversions. |
Run Time |
jql_divide_by_zero_zero = true|false |
For systems (R91), division by zero in conversions/correlatives will return zero. (The default behaviour is to return the numerator unchanged). |
Run Time |
jql_mv_subcall = true|false |
For systems (Sequoia) the user subroutine will be called for each multivalue and subvalue in data being processed by jQL. Default is false |
Run Time |
length_field_formatting = true|false |
For systems that preceed formatting with a length field. |
Run Time |
list_keys = yes|no |
If set then commands such as T-DUMP , T-LOAD , COPY will by default display all the record keys and use the (I) option to suppress this. Without this option then by default the reverse is true
e.g. T-DUMP will not list any record keys but the (I) option indicates that record keys should be displayed |
Run Time2 |
locate_null_only_in_array = yes|no |
Set for systems requiring null to only match within the real array, not the implied array, e.g. : FIND "" IN "abc" will return 'true' under the default mode. |
Run Time |
long_who = yes|no |
If set, the WHO command is extended to give the node name and UNIX account name. |
Run Time |
log_runtime_errors = true|false |
If true, runtime errors such as divide by zero are logged in the $JBCRELEASEDIR/runtime-errors directory, assuming the error message in $JBCRELEASEDIR/jbcmessages contains the string ^LOGERRORS^. |
Run Time |
make_locate_dr_like_dn = true|false |
Set for systems requiring the DR of the LOCATE statement to act like DN. |
Compile Time |
match_last_delimiter = true|false |
If set to 'true' then the last delimiter in pattern match string is used within the pattern to match, e.g.: "a]b]c]" will match "c]". |
Run Time |
matread_assigns_to_end = true | false |
Additional attributes are appended to the last element of a DIMensioned array by 'MATREAD'. By default additional attributes are returned in element '0' of the DIMensioned array.
Set 'true' under Sequoia emulation. [Runtime] |
Run Time |
md_int_only = true | false |
If set, only integers will be allowed in MD or MR conversions. If a decimal number is used then it will be treated as non-numeric, returning the original value,
e.g. OCONV(12.99,'MD2') returns '12.99' instead of '0.13' . |
Run Time |
multiple_cmd_execution = true | false |
For systems that allow execution of multiple commands if provided as a dynamic array to 'PERFORM'/'EXECUTE' statements. |
Run Time |
named_common = unassigned|null|zero |
Indicates how to set named common when first referenced. Default is unassigned.
'setting' can be :
|
a) "zero" to initialise to numeric 0. |
|
b) "unassigned" to keep it as an unassigned variable. |
|
c) "null" to create it as a zero length null string. |
| Run Time2 |
no_equate_on_call = true | false |
If set, inhibit the Equate processing on the 'Subroutine' name specified in CALL statements but not CALL @ statements. |
Run Time |
no_extra_delimiter = true|false |
For systems ( currently Sequoia and R83 ) which do not insert a delimiter (AM/VM/SVM) if the current string being appended to ( by specifying '-1' as the parameter to append/insert before )
has a 'trailing' delimiter (AM/VM/SVM ) already.
This behaviour is true for all of :
|
dyn_array<-1> = whatever , |
|
x = INSERT( dyn_array,-1,.., ..; whatever ), |
|
and |
|
INS whatever BEFORE dyn_array<-1,..,...> |
| Compile Time |
no_id_prompt = true|false |
For systems (Sequoia) which do NOT 'prompt for ids' when using 'QSELECT' (for example) and no items are specified.
If 'no_id_prompt' is set do NOT 'prompt' for the item ids but assume '*' (i.e. ALL items) are required. |
Run Time |
no_value_maths = true|false |
If set to 'true' then jBASE will NOT perform automatic multi-value maths on a non-numeric string, e.g. : A = "12":@AM:"3" + 1 will fail with a 'NON_NUMERIC' error. |
Run Time |
nopage_null_header = true|false |
For systems (as yet unknown) which do NOT expect a pause at the end of Page when a Null HEADING is requested in Basic. The default behaviour is to leave this 'flag' unset. |
Run Time |
null_eq_zero = true|false |
For systems (Universe) right justified null fields will sort equal to zero. |
Run Time |
oconv_format_null = true|false |
For systems whose OCONV functions force formatting of null values. |
Run Time |
oconv_no_mask_formatting = true|false |
For systems that do not use OCONV mask formatting when value is null or nonnumeric. |
Run Time |
oconv_no_scale_formatting = true|false |
For systems that do not using a scaling factor by default for OCONV formatting. |
Compile Time |
old_jql_output_style = true|false |
If set, the output from LIST and SORT will be in the Reality/Pick style, i.e. with 1 space between columns rather than the default of 4 spaces. |
Run Time |
openseq_creates = true|false |
When set, the jBC OPENSEQ statement will create the specified file if it does not exist. This parameter is set by default for Sequoia. |
Run Time |
page_0_header = true|false |
For systems (Sequoia) PAGE 0 will clear any existing HEADINGs and FOOTINGs. |
Run Time |
para_stacked_data = true|false |
Set by default under Unidata emulation.
Externally stacked 'DATA', passed from a Basic program to an 'EXECUTE'd PAragraph, is only used to satisfy 'INPUT' requests within the PAragraph and is not passed indirectly to programs 'EXECUTE'd from the PAragraph, e.g. :
|
Program : |
|
|
|
DATA 'input1' |
|
EXECUTE 'Paragraph' |
|
|
|
PAragraph : |
|
|
|
PA |
|
SELECT file |
|
C 'input1' will NOT be passed to the above 'SELECT' if 'para_stacked_data = true' |
|
<<'GetInput'>> |
|
C 'GetInput' above will be satisfied by 'input1' if 'para_stacked_data = true' |
| Run Time |
pq_Aquote_prepends_space = true|false |
( Currently not enabled under any emulation by default).
This option can be enabled to assist in the construction of 'commands' within the Proc Output buffer.
Specifically for Proc's where a required trailing space has been omitted during creation of the Proc, e.g. :
|
|
|
... |
|
... |
|
HSELECT <--- The trailing 'space' has been omitted within the Proc |
|
IP |
|
A' |
|
... |
|
... |
|
|
|
With this option enabled, the A' and/or A", will prepend a 'space' to the current contents of the Output buffer, where necessary, prior to appending the 'quoted' contents of the 'A' buffer, e.g. : |
|
|
|
When this option is enabled the 'Output' buffer will contain : |
|
SELECT 'input_data' |
|
rather than: |
|
SELECT'input_data'. |
|
|
| Run Time |
pq_backslash = true|false |
If set, PQ procs will use backslash delimiters when extending past the end of input buffer with Sn or Rin. Default for Sequoia. |
Run Time |
pq_indirection = true|false |
If set then PQ procs can execute PQN proc commands (Universe). |
Run Time |
prime_runtime_errors = true|false |
'ZERO_USED' , 'DIVIDE_ZERO' and 'NON_NUMERIC' errors generate message ids appended with '_PRIME', eg 'ZERO_USED_PRIME' , 'DIVIDE_ZERO_PRIME' and 'NON_NUMERIC_PRIME' etc. |
Run Time |
print_initial_formfeed = true|false |
Set by default under Ultimate emulation.
Under normal circumstances the leading form feed, from a HEADER, is suppressed in PRINTed output.
This emulation mode causes such form feeds to be PRINTed at the start of the PRINT jobs. |
Run Time |
prt_video = true|false |
Support the following extensions, mainly for printer definitions : @(-27) to @(-33) , @(-47) to @(-55) and @(-59) to @(-126) , and @(-220) through @(-239). |
Run Time |
quit_eq_end = true|false |
Quit (or Stop) from the debugger has the same effect as End or Abort, meaning any calling proc or paragraph is terminated. |
Run Time |
read_reset_as_null = true|false |
For systems which, when a read fails, reset the read variable to a null string. |
Run Time |
readnext_dont_null_last_key_on_eof = true|false |
If set, then retain the value of the last key on a READNEXT instead of setting it to NULL when EOF is reached. |
Run Time |
readv0 = binary|dcount|key |
When a READV (or READVU) is performed and attribute 0 is specified, this defines what to return:
binary |
return '1' if the record exits ( '0' otherwise ). |
dcount |
return the number of attributes in the record, if the record exists. |
key |
return the record key. |
|
Run Time
|
reality_video = true|false |
Support the Reality video extensions from @(-128) through @(-191) for video effects such as combinations of reverse, underline, flashing and so on.
These can usually be added to all emulations without harmful effects. |
Run Time |
reformat_append = true|false |
By default the REFORMAT command overwrites existing attributes. With this set, then the REFORMAT command will append a multi-value to existing attributes. |
Run Time |
report_bad_tapeblksz = true|false |
Attempting to write a 'NULL' tape block or a block which is larger than the attached tape block size will return the appropiate error code in SYSTEM(0).
This option is NOT set by default for any emulation. |
Run Time |
resize_array = true|false |
If true then the re-DIMensioning of arrays is permitted. Set to 'true' under 'Universe', 'Prime', 'Unidata' and 'Ultimate' emulations. |
Compile Time |
returning_am_delimited = true|false |
If set then data returned from the RETURNING/SETTING clause of the EXECUTE statement will be attribute mark delimited. Otherwise the data will be value mark delimited.
The default is true for Sequoia, otherwise false. |
Run Time |
round_neg_tozero = true|false |
Round -0.5 to 0 instead of to -1. This does not affect 0.5. |
Run Time |
scale_masked_string = true|false |
For systems (Reality) where formatted strings are descaled by the specified scaling factor, e.g.:
|
'123456' 'R26' gives : |
|
with 'scale_masked' set : '0.12' |
|
with 'scale_masked' unset : '1234.56'. |
|
Compile Time |
selected_count_not_binary = true|false |
SYSTEM(11), which returns the status of the default select list will, by default, return 1 if a default select list is present, or 0 if no default select list is present.
If this option is set, 'SYSTEM(11)' returns the number of items in the default select list. |
Run Time |
single_space_timedate = true|false |
The TIMEDATE() function uses a single space separator (default is two spaces). |
Run Time |
skip_pib_on_ip_null = true|false |
If set, leave PIB unchanged when null entered at IP command in PQ proc. |
Run Time |
skip_spaces_and_tabs = true|false |
For systems which ignore leading and trailing spaces when handling values for maths. |
Run Time |
sline_with_heading = true|false |
For systems (Prime), specifying a heading in jQL will NOT suppress the "n Records listed." messages. |
Run Time |
sp_assign_all = |
For systems (Reality), where SP-ASSIGN without a 'channel' number will assign the specified form to ALL 'channels'.
By default SP-ASSIGN without a specified 'channel' number only assigns to 'channel 0 (zero). |
Run Time |
spooler4_only_recent_jobs = true|false |
Set by default under Reality emulation.
Under normal cicumstances ALL print jobs for the specified port will be returned by the SPOOLER(4) function.
This emulation limits the information returned to those Print jobs created by the specified/current port, since the program issuing the SPOOLER(4) was started. |
Run Time |
stacked_input_global = true|false |
Set if the DATA stack operates globally or traditionally i.e. : determines whether 'unused' stacked DATA is still available on return from 'EXECUTE'. |
Run Time |
substring_zero_eq_one = true|false |
For systems (Reality) which treat a starting position of '0' as '1' in substring assignment, e.g. : x[0,1] = bla is equivalent to x[1,1] = bla.
The default behaviour, for 'x[0,n] = value' is to prepend to the original string.
With 'substring_zero_eq_one' set, the first 'n' character(s) are replaced, e.g. : where 'x' is originally 'abc', x[0,1] = 'z' will give : 'zbc' with 'substring_zero_eq_one' set and 'zabc' by default. |
Run Time |
system_19_timedate = true|false |
SYSTEM(19) will return a unique 'date + time' stamp, e.g. '1103361234' when compiled under this emulation, (rather than the 'account name'). (Sequoia emulation). |
Run Time |
tconv_no_replace = true|false |
By default the T conversion in OCONV will replace system delimiters. This causes that effect not to happen. |
Run Time |
time_is_hours = true|false |
For systems (Reality and Sequoia) ICONV(1,"MTS") will return 3600 (not 60). |
Run Time |
treat_with_as_and_with = true|false |
If set treat jQL WITH <Clause> WITH <Clause> as AND WITH - default is OR WITH. |
Run Time |
treat_with_as_or_with = true|false |
If set treat jQL WITH <Clause> WITH <Clause> as OR WITH - [ this is the default behaviour]. |
Run Time |
unnamed_common = unassigned|null|zero |
Indicates how to set un-named common when first referenced. Same as 'named_common'. |
Run Time |
use_id_lptr_reporting = true|false |
For systems (Prime) that use @ID and @LPTR for default listings. |
Run Time |
use_sql_syntax_for_select = true|false |
Use SQL syntax in SELECT commands. |
Run Time |
use_uv_locate = true|false |
When set to 'true', use the Universe syntax for the Basic 'LOCATE' function, i.e. 'search string' and 'array to search' parameters are interposed. |
Compile Time |
ux1ad_use_four_digits = true|false |
If set, user exits U11AD, U21AD and U31AD will generate four digit rather than two digit numbers. i.e. nnnnP vs nnP |
Run Time |
wrap_r_just = true|false |
For systems (Universe and Prime), right justified data will wrap in jQL. |
Run Time |
writelist_on_select_from_var = true|false |
If set then write any select list, generated by basic "SELECT Var" to the default select list. |
Run Time |
On many platforms, @(-n) codes are used to control special terminal characteristics. However the definition of these codes differs between platforms.
Rather than "hard coding" the @(-n) codes, jBASE allows their definition in the Config_EMULATE file.
This allows legacy applications to use existing @(-n) codes and so reduces the time required to port an application to jBASE.
A knowledge of terminfo capabilities can be useful when defining these codes.