Is connect as SYSDBA supported in direct mode?

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for Oracle
Post Reply
tomharris
Posts: 18
Joined: Tue 27 Jul 2010 12:22

Is connect as SYSDBA supported in direct mode?

Post by tomharris » Wed 23 Nov 2011 12:33

Hi there,

we are having problems with this. Is this supported in direct mode? We are getting an error ORA-28009: connection as SYS should be as SYSDBA or SYSOPER.

Any clues?

Kind regards, Tom

Pinturiccio
Devart Team
Posts: 2192
Joined: Wed 02 Nov 2011 09:44

Post by Pinturiccio » Thu 24 Nov 2011 11:54

If you want to connect to a server with User Id=sys, then you have to add the connect mode to your connection string.

Code: Select all

OracleConnection conn = new OracleConnection();
conn.ConnectionString += "Connect Mode=SysDba;";
OR

Code: Select all

OracleConnection conn = new OracleConnection();
conn.ConnectMode = OracleConnectMode.SysDba;
The enum OracleConnectMode has the following members:
Default
SysAsm
SysOper
SysDba

tomharris
Posts: 18
Joined: Tue 27 Jul 2010 12:22

Post by tomharris » Fri 25 Nov 2011 18:01

Thanks for your help. We got this sorted now

Post Reply