Skip to main content

How to suppress result output text of select statement in a proc command running in a phantom.

  • December 16, 2022
  • 5 replies
  • 0 views

The output of my select statement ie "3 records selected" is putting too much information in the PH file. How can I suppress that output in a PROC so those messages do not get written out while running in a phantom process?

------------------------------
[Gary] [Rhodes]
[Universe Developer]
[NPW Companies]
[Hialeah] [FL] [USA]
------------------------------

5 replies

Neil Morris
Forum|alt.badge.img
  • Rocketeer
  • December 16, 2022
The output of my select statement ie "3 records selected" is putting too much information in the PH file. How can I suppress that output in a PROC so those messages do not get written out while running in a phantom process?

------------------------------
[Gary] [Rhodes]
[Universe Developer]
[NPW Companies]
[Hialeah] [FL] [USA]
------------------------------
Using the 'PH' command in the proc should suppress the output as seen below. The output of the second SELECT is suppressed.

>COPYP VOC PQFORUM (TSN

PQFORUM
PQ
HSELECT VOC SAMPLE 1
P
HCLEARSELECT
P
HSELECT VOC SAMPLE 1
PH
HCLEARSELECT
P
4
>PQFORUM

1 record(s) selected to SELECT list #0.
SELECT list number 0 cleared.
SELECT list number 0 cleared.

------------------------------
Neil Morris
Universe Advanced Technical Support
Rocket Software
------------------------------

Doug Averch
Forum|alt.badge.img+1
  • Participating Frequently
  • December 16, 2022
The output of my select statement ie "3 records selected" is putting too much information in the PH file. How can I suppress that output in a PROC so those messages do not get written out while running in a phantom process?

------------------------------
[Gary] [Rhodes]
[Universe Developer]
[NPW Companies]
[Hialeah] [FL] [USA]
------------------------------
We have phantoms running all in the background in our applications.  The number of records is suppressed like this:

EXECUTE 'SELECT VOC' CAPTURING OUTPUT

Posted: 12-16-2022 16:26

------------------------------
Doug Averch
Owner
U2 Logic
------------------------------

John Jenkins
Forum|alt.badge.img+1
  • Participating Frequently
  • December 16, 2022
The output of my select statement ie "3 records selected" is putting too much information in the PH file. How can I suppress that output in a PROC so those messages do not get written out while running in a phantom process?

------------------------------
[Gary] [Rhodes]
[Universe Developer]
[NPW Companies]
[Hialeah] [FL] [USA]
------------------------------
There are a few other options on the PROC 'P' command as well - from memory:

P - Process 
PH - Print and Hush
PP - Print and Process
PW - Print and Wait for input - options are g  or C/R (go); s (skip) and x (exit)
PX - process and exit the PROC (not sure about this one - it's in D3 at least)
 
Regards

JJ

------------------------------
John Jenkins
Thame, Oxfordshire
------------------------------

  • Author
  • Participating Frequently
  • December 18, 2022
There are a few other options on the PROC 'P' command as well - from memory:

P - Process 
PH - Print and Hush
PP - Print and Process
PW - Print and Wait for input - options are g  or C/R (go); s (skip) and x (exit)
PX - process and exit the PROC (not sure about this one - it's in D3 at least)
 
Regards

JJ

------------------------------
John Jenkins
Thame, Oxfordshire
------------------------------
Thanks so much for the help. That works perfectly. Even with the code below it suppressed the output to &PH&.

HSELECT INVOICE
STON
HPROCESS.INVOICES
PH

Jonathan Smith
Forum|alt.badge.img+4
We have phantoms running all in the background in our applications.  The number of records is suppressed like this:

EXECUTE 'SELECT VOC' CAPTURING OUTPUT

Posted: 12-16-2022 16:26

------------------------------
Doug Averch
Owner
U2 Logic
------------------------------
Another alternative is in the PROC you could use the HUSH command as HUSH is used to suppress all text normally sent to the screen during processing.
The downside would be you wouldn't see if something went wrong.
If you are using Basic then the previous suggestion of EXECUTE cmd CAPTURING OUTPUT should work.
If you are just using PROC then the HUSH command will suppress ALL output, or the other alternatives already suggested will also work.
As usual many ways to solve the same problem.



------------------------------
Jonathan Smith
UniData ATS
Rocket Support
------------------------------