11.07.2015 Views

Caché ObjectScript Reference - InterSystems Documentation

Caché ObjectScript Reference - InterSystems Documentation

Caché ObjectScript Reference - InterSystems Documentation

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Caché</strong> <strong>ObjectScript</strong> Commands• Log on.• Issue a USE 0 command.• Cause an error when an error trap is not set.• Close the current device.• Return to programmer mode.• Exit <strong>Caché</strong> by issuing a HALT command.USE 0 implies an OPEN command to the principal device. If another process owns the device,this process hangs on the implicit OPEN as it does when it encounters any OPEN.Although USE 0 implies OPEN 0 for the principal device, issuing a USE command for anyother device that the process does not own (due to a previous OPEN command) produces a error.Note:While most <strong>Caché</strong> platforms allow you to close your principal input device, <strong>Caché</strong>for UNIX does not. Therefore, when a job that is the child of another job tries toperform I/O on your login terminal, it hangs until you log off <strong>Caché</strong>. At that time,the output may or may not appear.Using the Null Device (UNIX and OpenVMS)When you issue an OPEN and USE command to the null device (/dev/null on UNIX or NL:on OpenVMS), <strong>Caché</strong> treats the null device as a dummy device. Subsequent READ commandsimmediately return a null string (""). Subsequent WRITE commands immediately returnsuccess. No actual data is read or written. On UNIX-based systems, the device /dev/nullbypasses the UNIX open, write, and read system calls entirely.Processes started by other processes with the JOB command have a principal device of/dev/null or NL: by default.If you open /dev/null other than within <strong>Caché</strong> for example, by redirecting <strong>Caché</strong> output to/dev/null from the UNIX shell the UNIX system calls operate as they do for any other device.See Also• OPEN command• CLOSE command• $IO special variable• $PRINCIPAL special variable150 <strong>Caché</strong> <strong>ObjectScript</strong> <strong>Reference</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!