I receive this error:
java.sql.SQLException: ORA-28009: connection as SYS should be as SYSDBA or SYSOPER
How to fix? (I need to be SYS
). Thanks.
A JDBC URL provides a way of identifying a database so that the appropriate driver recognizes it and connects to it. In the Derby documents, a JDBC URL is referred to as a database connection URL.
try this :
import java.sql as jsql import java.lang as lang driver, url, user, passwd = ( "oracle.jdbc.driver.OracleDriver", "jdbc:oracle:thin:@localhost:1234:xxx1", "sys as sysdba", "xxx1") lang.Class.forName(driver) c = jsql.DriverManager.getConnection(url,user,passwd)
Answers already there,
you are trying to connect as sys
but the Server allows
either
sys as sysdba
or
sys as sysoper
just change user parameter as either one from above
user='sys as sysdba'
or
user='sys as sysoper'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With