Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Print option in Queryman

Status
Not open for further replies.

scarletAni

Programmer
May 14, 2003
22
IN
I want to print some results in a procedure and check for the correctness of values...

REPLACE Procedure
A.proc1
(OUT dt1 varchar(10), OUT dt2 Varchar(18))
Begin

DECLARE maxdttm_crfh char(18);
DECLARE maxdttm_dsth char(18);

call A.pr_get_next_asof( 'Temp1', 'Depnd1', :maxdt_dsth, :maxdttm_dsth );

Print maxdt_dsth;
Print maxdttm_dsth;

End;

I did a help

Help procedure A.proc1 Attributes;

And found that the PrintMode is 'N'
Can this be set back to 'Y' for a procedure and the values be printed ?
 
As far as I know there is no print statement that you can use in a stored procedure. You will need to insert the values into a table.

 
Hi,
The PRINT statement is being deprecated. It will no longer function in post 5.0.

In 4.1 the output of the PRINT statement goes to SCREEN 5 in the DBW window ( which is normally running on the AWS hidden inside the data center ) so its output is normally not accessible to the developers.

If you have access to the DBW you can see the output of the print statement.

I would recommend.....

Follow the directions in the SQL Reference Manual Volume 6 stored procedure chapter on setting up a TEMP LOG table and then insert log messages into the TEMP table.

V2r5

V2r4.1.x


After you run the stored procedure you select the output output of the LOG table.
 
To be able to use print in V2R4 you have to enable it in your ODBC connect:
options -> advanced options -> the ProcedureWithPrintStmt

But it's almost useless, so use tdatgod's temp table instead.
I still hope there'll be a debugger for SPs someday...

Dieter
 
Thans for all those inputs !!
Yeah !! Waiting for a debugger for SPs...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top