Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Message on screen

Re: Message on screen

From: John Leggitt <johnml_at_istar.ca>
Date: 1998/03/30
Message-ID: <lqFT.70$b$4.699741@NewsRead.Toronto.iSTAR.net>#1/1

You can also use a package called DBMS_OUTPUT to output text, variable values, etc from within PL/SQL blocks.

Example:

DBMS_OUTPUT.PUT_LINE('This is an example. ' || mystringvar || ' How about a number: '
 || TO_CHAR(mynum) );

DBMS_OUTPUT.PUT_LINE takes a single string as a parameter (That is why I have TO_CHARed a number and concatenated ( || ) everything together. mystringvar and mynum are variables already declared and assigned values that you want to check or see in SQL*Plus.

Make sure you issue a SQL*Plus command: SET serverout ON before using this.

Good luck
JohnL

Richard Fairbairn wrote in message <1998032915033876740_at_zetnet.co.uk>...
>Can someone spare a moment to tell me how I can make a message appear
>in the SQL*Plus interpreter screen? I do not want my program to
>terminate on display of this message. I'd like the message to show a
>description of what is currently occurring during processing.
Received on Mon Mar 30 1998 - 00:00:00 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US