The EXCHANGE Proc exchanges the data in two items in a specified file. The file items retain their original item-IDs.
Format
EXCHANGE [DICT] filename item1 item2 |
Parameter(s)
DICT |
Specifies the file dictionary. |
filename |
Name of the file. |
item1 |
First of the two file items. |
item2 |
Second of the two file items. |
Description
Item-IDs do not require quotes unless they include blank spaces.
Exchanging the Data in Two File Items
The following example exchanges the data in the items BUCKNER and BUCKNELL in the CUSTOMERS file:
>EXCHANGE CUSTOMERS 'BUCKNER' 'BUCKNELL' COPY CUSTOMERS 'BUCKNER' 'BUCKNELL' %TEMP% (O,D) %TEMP 'BUCKNER' 'BUCKNELL' _ ?<ENTER> 1 BUCKNER TO %TEMP% 2 BUCKNELL TO BUCKNER 3 %TEMP% TO BUCKNELL
3 ITEMS COPIED |
The system displays status messages as it performs the copy operations. When the ? prompt is displayed, press ENTER to complete the data exchange, as shown above.