Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORA-03111 in Entity Framework

3307309Sep 2 2016 — edited Sep 5 2016

Hello!


I'm building an ASP.Net MVC 5 with Entity Framework 5. In one of my Stored Procedure with 1 Input and 1 output parameter I'm getting the error ORA-03111: Break received on communication channel. I also have 2 other SP with same signature (1 Input and 1 Output) and they are working well. I already read a lot in this error but nothing works:

- This blog http://royontechnology.blogspot.com/2009/06/mysterious-ora-03111-error.html, I increased the timeout (this.Database.CommandTimeout = 10000;) still stays the same;

- Also read that could be because of Managed Access is only compatible with 10.2 or higher, but I'm using 11g.

My code on the application is:

public virtual List<TIM_USER_CUSTO> GET_USER_CUSTO(string p_ANOMES)

        {

            try

            {

                var p_ANOMESParameter = new OracleParameter("P_ANOMES", OracleDbType.Varchar2, p_ANOMES, ParameterDirection.Input);

                var p_refCursor = new OracleParameter("USER_CUSTO", OracleDbType.RefCursor, ParameterDirection.Output);

                this.Database.CommandTimeout = 10000;

                return this.Database.SqlQuery<TIM_USER_CUSTO>(

                            "BEGIN TIM_FUNCTIONS.GET_TIM_USER_CUSTO(:P_ANOMES, :USER_CUSTO); end;",

                            p_ANOMESParameter, p_refCursor).ToList();

            }

            catch (Exception e)

            {

                return null;

            }

        }  

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 3 2016
Added on Sep 2 2016
12 comments
1,660 views