Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Zugriff auf Oracle mit JDBC

Empfohlene Antworten

Veröffentlicht

Moin!

Ich möchte mit Java auf ne Oracle DB!

Fehlermeldung:

problems connecting

java.sql.SQLException: E/A-Exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=153093376)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))

Connection con = null;
try {
Class.forName("oracle.jdbc.driver.OracleDriver");
String usr = "java0";
String pw = "test1";
String url = "jdbc:oracle:thin:@13.13.101.3:1521:java0";
con = DriverManager.getConnection(url,usr,pw);
System.out.println("Connected!");
} catch (Exception e) {
System.err.println("problems connecting");
System.out.println(e);
}[/PHP]

Mir wurde gesagt das der user java0 auch die DB ist!

Ich benutze den WSAD 5.1 (Java 1.3.1) und die classes12.zip von Oracle!

Jmd ne Lösung? Hab ich was vergessen?

Huhu popeye,

ich würd noch mal prüfen, ob der Connect-String

(jdbc:oracle:thin:@13.13.101.3:1521:java0) so OK ist (müsste in der Doku des

Oracle-JDBC-Treibers stehen).

Ansonsten gibts eventuell ein Firewall-Problem. Vielleicht mal

ein Telnet auf 13.13.101.3:1521 versuchen. Wenn das nicht klappt, liegts

wahrscheinlich daran.

LG,

Feli :)

(ERR=[B]12505[/B])(ERROR_STACK=(ERROR=(CODE=[B]12505[/B])

ORA-12505: TNS: listener could not resolve SID given in connection description.

heisst, er kann die datenbank-SID nicht umsetzen, weil sie nicht angegeben wurde.

jdbc:oracle:thin:@13.13.101.3:1521:java0

ich glaube, statt java0 gehört nicht der username, sondern die SID (datenbankname).

check das mal in deiner tnsnames.ora, ob die angabe die du bekommen hast überhaupt stimmt.

s'Amstel

  • Autor
(ERR=[B]12505[/B])(ERROR_STACK=(ERROR=(CODE=[B]12505[/B])

ORA-12505: TNS: listener could not resolve SID given in connection description.

heisst, er kann die datenbank-SID nicht umsetzen, weil sie nicht angegeben wurde.

jdbc:oracle:thin:@13.13.101.3:1521:java0

ich glaube, statt java0 gehört nicht der username, sondern die SID (datenbankname).

check das mal in deiner tnsnames.ora, ob die angabe die du bekommen hast überhaupt stimmt.

s'Amstel

Merci beaucoup!

Auf ein weiteres Nachfragen wurde mir dann mal die korrekte SID genannt!

Ich bin druff! Danke schön!

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.