SQL/MX 2.x Reference Manual (H06.04+)

MXCI Commands
HP NonStop SQL/MX Reference Manual540440-003
4-44
RESET PARAM Command
RESET PARAM Command
The RESET PARAM command is used to clear all parameter values or a specified
parameter value within an MXCI session.
You can use RESET PARAM only within an MXCI session.
?param-name
is the name param-name of the parameter for which the value is specified. If you
do not specify param-name, all of the parameter values in the current MXCI
session are cleared. If you want to clear several parameter values but not all, you
must use a separate RESET PARAM statement for each parameter.
See MXCI Parameters on page 6-73.
Examples of RESET PARAM
Before you can execute a SELECT statement with parameters, you must specify
the parameter values. Clear all parameter values so that unexpected values are
not provided during execution of the FINDSUPP file.
RESET PARAM;
SET PARAM ?ST 'TEXAS';
SET PARAM ?PN 3210;
Execute the SELECT statement as follows:
SELECT S.suppnum, suppname
FROM sales.supplier S,
invent.partsupp PS
WHERE S.suppnum = PS.suppnum AND
partnum = ?PN AND state = ?ST;
SUPPNUM SUPPNAME
------- ------------------
15 DATADRIVE CORP
--- 1 row(s) selected.
Reset only one parameter:
Display the parameters:
>>SHOW PARAM;
PARAM ?ST TEXAS
PARAM ?PN 3210
RESET PARAM [?param-name]