UP

Moves the current member pointer one or more records “up” in a result set.

Syntax

UP [num] [setname]

Parameters

numCan be:
an integer constant (15, 200);
a variable, form field, or parameter that evaluates to an integer;
the word ALL.
The default value of num is 1.
If num is negative, the command effectively becomes a DOWN or NEXT command.
setnameThe name of a result set. If setname is omitted, the current set is used.

Comments

PREVIOUS is a synonym for UP.

Example

up 10

Moves the current member pointer 10 members “up” towards the start of the set.

up 5 MySet

list 5 MySet

Moves the current member pointer five members “up”, then lists five members (starting with the new current member).

See Also

$currentmember

BOTTOM

DOWN

LOCATE

NEXT

PREVIOUS

TOP

DDEExecute

DDEExecute

Send commands and macros to the target application.

Syntax

procedure DDEExecute (out tErrCode, inout tServ,
 in app_cmd)

Parameters

tErrCode

longint, an error code

tServ

longint, connection handle

app_cmd

char, command or macro to be executed

Comments

DDEExecute sends target application specific commands and macros to be executed by the remote application. Consult the documentation of the remote application for information on these commands.

The filename is ddeexec.pgm.

Example

For example, given that DDE_Err and hServ are of type longint and that hServ has been set by a previous call to DDEConnect, to send the ‘[NEW(1)]” command to EXCEL

DDEExecute(DDE_Err, hServ, ‘[NEW(1)]’)

instructs EXCEL to open a new spreadsheet.

SET NULLVALUE

Specifies the characters to be displayed for $Null values.

Syntax

SET NULLVALUE constant

Parameters

constant

A character string, or an expression that evaluates to a character string.

Comments

The NULLVALUE option is set to a space character by default.

When a value to be output is $Null, the specified constant is displayed.

Example

To specify that the character constant NA is to be displayed for $Null expressions, use

> set nullvalue “NA”

As a result, a LIST command looks like this:

> list 3 Employees
 
LastName    FirstName    Salary
Smith      John        25000
Jones      NA         35000
Johnson     Janet        NA

 

See Also

$Null

Expressions and the $Null Property

WHERE (Condition)

WHERE

States a condition.

Syntax

WHERE expression

Parameters

expression

A logic expression using conditional and Boolean operators.

Comments

WHERE states the conditions that restrict processing in the main command to only certain members of the set specification, contingent on a value within each of the (related) records being considered.

Of all the available (related) records in the record-containing objects, only those records for which the condition is logically true become members of the set.

Example

list all Employees where LastName = Smith and FirstName = J?

The preceding command lists only those employees whose last name is Smith and whose first name starts with the letter J.

 

See Also

About Boolean Expressions

About Conditional Expressions

ADD

CHANGE

COMPUTE

DELETE

DELETE FROM

INSERT

LIST

REPORT FROM

SELECT

UPDATE

SET XML ROWELEMENT

Defines the title of the row element

Syntax

set xml rowelement constant

Parameters

constant

A character string or an expression that evaluates to a character string

Comments

SET XML ROWELEMENT defines the identification of the row element for each row data that is printed whenever the set output format xml or xmlsimple is set. By default, ZIM prints the pair ….

Example

set save

set output format xmlsimple

set xml rowelement /p>

set output MyDoc

list 1 Docs

set restore

 

See Also

SET OUTPUT FORMAT

SET XMLHEADER

SET LEXTRACE

Controls lexical tracing.

Syntax

SET [LOCAL] LEXTRACE ON|OFF

Parameters

LOCALIndicates that lexical tracing is to be switched ON or OFF only at the “local” level.

Comments

The LEXTRACE option is set OFF by default.

When LEXTRACE is ON, each line of a procedure is displayed on the terminal, one character at a time, as it is parsed. Each line is preceded by the procedure name and document line number. If an error occurs, the resulting error message appears immediately following the character that caused the error.

Comment lines are traced. Carriage returns are inserted into the output when continuation characters (backslashes) are encountered. Statements are shown after macro substitution (if any) is complete.

Each output line starts with the procedure name and the application document line number as shown in the following example:

pCustReport[19] report from Customers

The SET LEXTRACE command has no effect on compiled procedures.

The SET LEXTRACE command is not affected by the SET RESET and SET RESTORE commands.

See Also

SET COMMANDTIMING

SET TRACE

SET TRACEOUTPUT

DISPOSE

Releases memory occupied by user-defined variables (including form fields and menu items) or result sets.

Syntax

DISPOSE option

Parameters

optionCan be
«item»
The name of a variable, form field, menu item, form or menu whose current memory allocation is to be released.
ALL
Releases the current memory allocation of all user-defined variables, form fields, and menu items.
SET
Causes all result sets to be reset to empty.

Comments

DISPOSE releases the memory where the current values of variables (including form fields and menu items) are stored. As a result, the objects whose values were stored in that memory become $Null. DISPOSE does not close or erase the objects themselves.

Example

dispose all

Releases memory used to store current values of all variables, form fields, and menu items in an application.

dispose Form1 Menu1

Releases the memory used to store the current values of all form fields in the specified form and menu.

$cos

Calculates the cosine of a number.

Syntax

$cos(number)

Parameters

numbera number, or an expression that evaluates to a number

Return Value

Number, with the same number of decimal places as number.

Comments

The value returned by this function has the same number of decimal places as number. Ensure that you specify enough decimal places in your equation to ensure a sufficiently granular result. Unusual results such as
-0 are an indication that the number of decimal places needs to be increased. For example, if you enter

$cos(2)

without any decimal points, you receive the result

-0

However, if you enter

$cos(2.0000)

you receive the result

-0.4161

Example

$cos(0)

Evaluates to 1.

let var1 = 3.14
let var2 = $cos(0.50*var1)

Var2 evaluates to 0.00.

See Also

$acos

$cosh

$sin

$tan

About Functional Expressions

$atan2

Calculates the arctangent (in radians) of the quotient of two numbers.

Syntax

$atan2(number1,number2)

Parameters

number1a number, or an expression that evaluates to a number
number2a number, or an expression that evaluates to a number

Return Value

Number, with the same number of decimal places as number1.

Comments

Number1 is divided by number2 before the arctangent is calculated.

The value returned by $atan2 has the same number of decimal places as number1.

Example

$atan2(1.000,2)

The above command is equivalent to $atan(0.500) and returns the value 0.464.

See Also

$acos

$asin

$atan

$tan

$tanh

About Functional Expressions

DECRYPT

Decrypts the data in an EntitySet or relationship with fields.

Syntax

DECRYPT object

Parameters

objectThe name of a previously encrypted entity set or a relationship with fields. A role name can be used.

Comments

Reverses an ENCRYPT command.

If the data in the specified EntitySet or relationship was not previously encrypted, the command raises an error.

The ENCRYPT and DECRYPT commands prevent users outside of an application session from reading sensitive data contained in disk files. Within Zim, encrypted data is automatically decrypted as the application programs work with it. All encryption and decryption in a particular database is based on a key established when you initiate a new database by executing the New Database (ZIMINIT) administrative utility.

Encrypted EntitySets and relationships are accessed in exactly the same way as unencrypted EntitySets or relationships. Internally, the software automatically decrypts data from an encrypted file as you work with that file. A slight performance penalty is paid for working with encrypted data.

See Also

ENCRYPT

Securing Data Inside an Application

en_CAEnglish