File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Print Oracle DBMS_OUTPUT in Java, HOW? Help Please!

 
Bo Lin
Greenhorn
Posts: 6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello, I have a stored procedure/trigger in oracle that does something like:
dbms_output.put_line("hello world")
dbms_output.put_line("bla bla")

Now I am using Java/JDBC to access this oracle stored procedure/trigger and want to display the dbms_output ("hello world" "bla bla") etc within the Java GUI. How do i do that? Any help will be greatly appreciated, thank you.
Bo
 
Pradeep bhatt
Ranch Hand
Posts: 8927
Firefox Browser Java Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The answer is - U cannot.
 
Jamie Robertson
Ranch Hand
Posts: 1879
MySQL Database Suse
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
you can't print directly from the procedure as stated earlier, but you can save the message as a VARCHAR in the procedure and return it as an out parameter. In java you can read the out parameter and System.out.println() the return message.
Jamie
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic