invantive documentationpart of invantive cloud
Invantive Support ForumsLog In / Sign Up

Quoting

A text value handed to an Invantive Script statement is written between double quotes. The rules below hold for every statement which takes such a value, among them Define, Host, Export Results and Show Message.

Writing a Quoted Value

A quoted value opens with a double quote and closes with one. Everything in between is the value:

  • A double quote which belongs to the value itself is written twice. The pair "" inside a value stands for one double quote.
  • A backslash is an ordinary character. A path such as c:\temp\output is written as it stands, and nothing in it has to be escaped.
  • "" on its own is the empty text.
  • A reference ${NAME} inside the value is replaced by the value of that variable, as Variables describes.

This is the rule from release 27.0 onward. Up to and including release 26.0 a double quote inside a value was treated differently by each statement, and most statements could not carry one at all.

Examples

A variable holding a Windows path, written without escaping:

local define OUT_PATH "c:\temp\step2\step3"

An operating-system command whose arguments carry a quoted path of their own. Each doubled quote is one quote of the argument text and reaches the command as a single quote:

local host "zip" "-9 -v ""${OUT_PATH}\results.zip"" *.xml" "c:\temp"

A variable defined as the empty text:

local define SUFFIX ""

Case of Keywords

The keywords of Invantive Script are case-insensitive, local among them, so local define, LOCAL DEFINE and Local Define are one and the same statement. Available from release 27.0. Up to and including release 26.0 a keyword had to be written in lower case.

The name of a variable is case-insensitive as well, as Variables describes. A value, a column name and a file name keep the case in which they are written.

Order of Options

Where a statement takes a set of options, the options may be written in any order. This holds for the options of Export Results which follow format, and for the options of Log on. Available from release 27.0. Up to and including release 26.0 the options had to be written in the order in which this documentation lists them, and any other order was refused.

An option written twice is refused, whichever order the options are in.