Receiving Error ORA-3106 in Toad when running dbms_output.put_line

Receiving error ORA-03106 when running simple dbms_output.put_line in Toad. All other procedures for dbms_output work fine.

Has anyone ever come across this?

Which version of Toad is this?

If not the latest (16.1), please try the latest, if you have access to it. I did make some bug fixes with dbms_output in recent versions. All is well with 16.1 as far as I know.

If you are using a VPN, please try it on a database that does not require VPN connection, if you have one.

We had a support case with one customer who had this problem while connected to VPN. Turned out, after a lot of digging, that something was blocking Toad in the VPN - and weirdly, it only blocked anonymous pl/sql blocks.

I'm also having ORA-03106: fatal two-task communication protocol error message in the Toad. It was working fine till couple of days back. Now start giving this error when executing anonymous pl/sql block which has DBMS_OUTPUT.PUT_LINE statement.

If the block doesn't have DBMS_OUTPUT.PUT_LINE statement then it works fine. It's kind of bothering me alot. We always working on VPN connection since we are working from home. Without VPN connection we cannot login to the Database.

My Toad version is 12.11.0.95 . So if I updated to 16.1 version the problem gets fixed automatically without any configuration?

Please let me know.
Thanks.

It's really hard to answer that question, but I can tell you that a lot of bugs have been fixed since version 12.11, so - maybe.

The latest version is 16.2. You could download a trial of 16.2 and see if the error happens there. Toad for Oracle Developer Edition | Free Trial

I'm 16.2.98.1741 and I'm getting this error. If I use the old 13.1 I dont get it.

Please turn on Spool SQL and post the output so we we can see which SQL is causing the problem.

Main menu -> database -> Spool SQL -> Spool to Screen.

Then make some dbms output happen and the Spool SQL window will collect the SQL that Toad executes, along with any errors.

Interesting it did not error in our test box. Only in prod and I cannot replicate it in Prod.

If your dbms_output calls created less than 10 lines of output, try again with more than 10 lines of output. Sorry, I forgot to mention that before.

Toad uses a simple method for the first 10 lines, and if there are more than 10 lines of output, it switches to a different method (involving CLOBs) after that to get the remaining lines all at once.

If more than 10 lines causes the problem, you can do this to fix:

  1. Shut down Toad.
  2. Find Toad.ini and double-click to edit with notepad
  3. Under [SETTINGS], add this line: FetchDBMSOutputByLob=0
  4. Save and close Toad.ini
  5. Try again in Toad

Hello
we're also having ORA-03106: fatal two-task communication protocol error message in the Toad.
It was working fine till couple of days back. Now start giving this error when executing anonymous pl/sql block which has DBMS_OUTPUT.PUT_LINE statement
but we've got error ONLY when connect to one specific instance.
When executing anonymous pl/sql block which has DBMS_OUTPUT.PUT_LINE statement in other instances, it works without errors

We try with less than 10 lines of output and more than 10 lines of output: always error

Can you help us understand the problem?
Thanks
best regards

If you are not on version 16.3 and can update, then update. That should resolve it.

If you can't update, or if that doesn't resolve it, try adding the FetchDBMSOutputByLob=0 setting as described above.

If you are on 16.3 and having problems, please turn on Spool SQL (also as describe above) and post the output here.

I have been receiving this error for quite some time now and I figured out a way to resolve it. What I think the issue is that the button that enables the DBMS Output has a bug. So simply, execute this command before using the DBMS_OUTPUT, SET SERVEROUTPUT ON; Also, use the DBMS_OUTPUT within a BEGIN and END block.

Still a bug needs to be fixed, but at least there is a work around for it.

Ahmed, what Toad version are you on?

As far as I know, in version 16.3, there is no bug with DBMS_Output. There were some problems in the versions before that, but I think they've all been resolved. If you still have some problem, please turn on spool SQL to capture the error and post the entire spool output here (or you can email it to me if you don't want to post it publicly)

Thank you.

This is a workaround:
if you put SET SERVEROUTPUT ON at the beginning of the script, before the declare, it works fine