Can I connect via jdbc thin like "sqlplus / "?

Hi all,
do you have a solution to connect to Oracle using
DriverManager.getConnection
like sqlplus' feature to login without authentication?
I tested the settings using sqlplus from cmd line, fine.
Using JDBC, I can't succeed...
TIA, Hans

You mean using Java?
If you are using Java, then it can work with:
con=DriverManager.getConnection
("jdbc:oracle:thin:@IP:PORT:SID","UserName","Password");      
It works fine with my code.
Sincerely,
Rachel

Similar Messages

  • Connecting via JDBC (thin) to 8i -- Error

    Hi --
    I'm trying to connect to a database on NT (resides on my
    workstation) and I get "Connecttion Reset by Peer"
    I'm using Oracle thin driver and db version is 8.1.5 for NT.
    TIA
    Ashish
    null

    Ashish (guest) wrote:
    : Hi --
    : I'm trying to connect to a database on NT (resides on my
    : workstation) and I get "Connecttion Reset by Peer"
    : I'm using Oracle thin driver and db version is 8.1.5 for NT.
    : TIA
    : Ashish
    a jdbc thin connection requires a tcp/ip listenrer to be active
    on the "server" machine.
    in this case it's also your "client" pc.
    null

  • Error trying to connect via jdbc

    I'm trying to connect via jdbc driver from a java application to a remote db. The code is quite simple
    DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    Connection conn = DriverManager.getConnection
    ("jdbc:oracle:thin:@dbhost:orcl", "user", "password");
    in my CLASSPATH I have the ojdbc14.jar file
    When I run this program I get the following error:
    Exception in thread "main" java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:334)
    at oracle.jdbc.ttc7.TTC7Protocol.handleIOException(TTC7Protocol.java:366
    8)
    at oracle.jdbc.ttc7.TTC7Protocol.logon(TTC7Protocol.java:353)
    at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:371)
    at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.ja
    va:551)
    at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:351)
    at java.sql.DriverManager.getConnection(DriverManager.java:525)
    at java.sql.DriverManager.getConnection(DriverManager.java:171)
    at Test.main(Test.java:12)
    Please be aware of the following facts:
    1) sqlplus from the same machine has no problem connecting to the db
    2) there is no firewall or router between the client and the server
    3) As host name I've tried the fqdn (resolved by the DNS), a name I've set up in /etc/hosts, the mere IP address
    4) Checking with tcpdump, I've verified that NO network packet actually leaves the client, so the problem completely lies there.
    Has anyone some good idea why this happens?

    Make sure you are providing correct hostname and listener port number

  • Can't connect via PPPoE in menu bar

    Hello,
    After not touching my Network Configuration settings for like three years, a glitch in my Unison 1.8.1 newsreader prompted me to go in to check, but I then encountered the prompt that has been afflicting lots of people: "Network settings have been changed by another application."
    So after some research here and via Google, I deleted /Library/Preferences/com.apple.networkConfig.plist and restarted the computer with the file still in the trash.
    I then manually reentered my ISP Network Configuration info (TCP/IP and PPPoE, as I use ADSL), but since then, I have only been able to connect via the Internet Connect program, rather than my preferred method that I've always used of connecting by using the PPPoE drop-down menu "Connect" command in the menu bar in the upper-right-hand corner of the screen.
    Going back to System Preferences' Network Configuration, showing the Built-in Ethernet's PPPoE panel, the "Show PPPoE status in menu bar" box remains checked, and indeed does display in the menu bar, however, only with a functioning "Disconnect" command -- NOT the "Connect" command, whose functionality I am seeking to restore.
    I realize this is more of a cosmetic problem, as I can still connect via the Internet Connect program, but would appreciate any tips for restoring the functionality of the PPPoE drop-down menu "Connect" command in the menu bar. Thanks in advance!

    Hi Steve, and a warm welcome to the forums!
    Safe Boot , (holding Shift key down at bootup), use Disk Utility from there to Repair Permissions, move these files to the Desktop.
    /Users/YourUserName/Library/Preferences/ByHost/com.apple.networkConnect.<12 digit number>.plist
    /Users/YourUserName/Library/Preferences/com.apple.internetconnect.plist
    /Library/Preferences/SystemConfiguration/preferences.plist
    /Users/YourUserName/Library/Preferences/com.apple.systempreferences.plist
    Then reboot once more.

  • I have the new IPad and can't connect via bluetooth to any of my apple devices (IPhone 4s and appleTV) neither from my new IPhone 4s. When I turn the Bluetooth on, both devices keep in searching mode... I don't know what to do now... Please help

    I have the new IPad and can't connect via bluetooth to any of my apple devices (IPhone 4s and appleTV) neither from my new IPhone 4s. When I turn the Bluetooth on, both devices keep in searching mode... I don't know what to do now... Please help... I can't pair any device because they can't find whitin themselves.

    Wmorlac wrote:
    I have the new IPad and can't connect via bluetooth to any of my apple devices...
    Correct... See Supported Bluetooth Profiles Here...
      http://support.apple.com/kb/HT3647
    Suggest you check the User Guides of your Devices to find the Method of what you are trying to do

  • D-Link wireless + Cable Internet:: can't connect via AirPort

    Just got my service changed from DSL to Cable and can't connect via wireless (but can with an Ethernet cable). Have tried the Wi Router settings to no avail. Any ideas? I think I might not be doing some setting in the comp correctly. Please help. Router is D-Link DIR-625.

    Did you open Airport and see if you see the wireless router? If you can see it, you can select it and then make sure it is set up properly in networks in the system prefs.

  • I have an iMac running OS X 10.8.3 and have connected an Epson Workforce 2540 printed that is allegedly Airprint enabled. I can connect and print with a USB cable but can't connect via Airprint. My colleague running 10.7 can. Is this a feature of 10.8?

    I have an iMac running OS X 10.8.3 and have connected an Epson Workforce 2540 printed that is allegedly Airprint enabled. I can connect and print with a USB cable but can't connect via Airprint. My colleague running 10.7 can. Is this a feature of 10.8? Any ideas for a fix?

    iOS devices use AirPrint to connect to a supported printer. OS X will use Bonjour to locate and connect to the same printer.
    With the Epson connected to your wireless router, when you open Print & Scan and click the plus button to add, does the Epson appear in a small box with a heading of Nearby Printers?
    If not and a window appears showing Default, Fax, IP and Windows in the toolbar, do you see the Epson with the Default view selected?

  • Can't connect via webdav to server 4

    Since upgrading to Server.app 4, I can't connect via WebDav. I keep getting one of two connection errors:
    1., "Unable to connect to the server. Check your internet connection and server name." 
    2., "Authorization error: Please check your login and password for this server."
    I am using the same login and pwd as sftp, which works just fine. Also, I am on the same network as the server.
    Any help would be greatly appreciated.

    I've had similar issues. I haven't completely resolved them, so I went back to Mavericks/Server 3 and I'll wait for an update. For what it's worth:
    1. I was able to sign in as a different user. Both users (successful and failed) have the same permissions on the WebDave share, according to Server 4.
    2. I never was able to sign in from a Windows 7 machine. The discussion linked below explains why:
    https://discussions.apple.com/thread/6621349
    Maybe something here will help

  • Can you connect via thunderbolt a mac book air 13" (2013) and a imac 21" (2013) together, using the iMac 21" as a 2nd screen

    Can you connect via thunderbolt a mac book air 13" (2013) and a imac 21" (2013) together, using the iMac 21" as a 2nd screen

    Welcome to Apple Support Communities
    Of course. As both have Thunderbolt, it's as simple as buying a Thunderbolt cable, connect them and press Command and F2 keys on the iMac, so the iMac will be used as an external display for the MacBook Air. If you want more information, see > http://support.apple.com/kb/PH11302

  • Officejet 6500A Plus E 710n. Can I connect Via Ethernet & WIFI SIMULTEANOUSLY?

    Officejet 6500A Plus w/ Windows XP on Desktop, Windows7 on Laptop. Can I connect Via Ethernet & WIFI SIMULTEANOUSLY?

    No.  You can have one or the other.  How the printer connects does not have to match how the computers connect.
    Say thanks by clicking "Kudos" "thumbs up" in the post that helped you.
    I am employed by HP

  • Connection through jdbc thin client taking more time than from sqlplus!!!

    Hello All
    Machines A and B
    Applicaion in A is connecting to B(9.2.0.6),db server.
    The schema is so small with few tables and data in each table less than 500 rows
    We are in the process of migrating the Application Schema in B to C[9.2.0.8].
    But the response time is more when the application fetches from C.
    Even while selecting the sysdate from dual.
    The application is using the jdbc thin client for fetching the data.
    When the same sql is executed by (from A to C)
    sqlplus -s user/pass @execute.sql, its gets done in a fraction of a second.
    But when the same is done through the application which uses jdbc thin client, it takes few seconds
    to complete.
    When tried with a small java program that uses classes12.jar (from A to C)
    conn = DriverManager.getConnection(URL,UID,PASS);
                   stop = System.currentTimeMillis();
                   System.out.println("Connection time in milli sec: " + (stop - start));
                   System.out.println();
    ..It was found that creating the connection was taking time.
    But the same is not happening when tired through the sqlplus
    Could someone throw some light into this?
    What could be the reason for jdbc to get slower while establishing connections?
    TIA,
    JJ

    are you using latest drivers - http://www.oracle.com/technology/tech/java/sqlj_jdbc/index.html
    you may want to check some options reducing jdbc connection cost from the otn samples - http://www.oracle.com/technology/sample_code/tech/java/sqlj_jdbc/index.html

  • Powerbook G4 can't connect via ethernet but connects via airport

    We have a small office network connected to an Efficient Networks DSL router that's managed by our isp. The router has 4 ports and a linksys 8 port switch is connected to one of those ports. Another D-Link wireless router/switch is connected to another port.
    2 i-macs connect without problem via ethernet cable. They are set to DHCP and get 192.xx private addresses. Both run 10.4.5. Another older imac running 9.2.2. also has no problems.
    I recently purchased a powerbook G4 and it will not connect via ethernet to the Efficient networks router. At first it was connected to the linksys, so decided to connect it direct to the Efficient Networks router. With DHCP, it acquires a 169. internet address which is self generated (i.e. no real connection). I tried to give it a static private address (talking to the isp provider). They could see the powerbook but saw all zero's (presumable mac address). By the way the Powerbook works perfectly at home connected via ethernet cable to a D-Link router connected to a cable modem so it's not a physical problem. I even checked the ethernet cable I used in the office with another computer - no problem.
    When I switch to airport in the office, the powerbook connects to the network and the internet. I get some strange warning messages showing the server's and the router's private ip addresses. I click ok, and the powerbook finds an unassigned private ip address. It's the only way it will work, but it causes problems, because I can't connect to one of the network printers. Speed also isn't great.
    Can anyone give me advise how to proceed. I am no expert on this stuff so keep it as simple as possible.
    Tks

    Tim,
    Thanks for your help. Here's what I've done before reading your e-mail. The D-Link DI-524 wireless router is connected to the Effiicent Neworks DSL router as you mentioned. One ethernet port of the EFF.Net. router is connected to the WAN port of the DI-514.
    Because I have a D-Link router at home which works flawlessly with my powerbook, I decided to connect the ethernet cable of the powerbook to the D-Link which has 4 ethernet ports. Lo and behold, the powerbook acquired a private ip address and connected to the LAN and internet!
    When I connected the powerbook direct to the Efficient Networks router, it could not communicate. I believe that there must be some software incompatibility between the powerbook and the Efficient Networks router. By connecting to the D-Link, the D-Link assigned an ip address to the powerbook, and it could connect to the server, lan, etc..
    Only problem is that I have a Brother network printer that cannot connect to the powerbook. My powerbook cannot find it on the network. Because there is a linksys switch connected to the efficient networks router's third ethernet port, maybe as you said, going through the D-Link via DHCP (when the Linksys is also acting as a DHCP server, might cause this type of problem. What do you think?
    As a final note, other imac G5's connected to the linksys switch (which then connects to the Efficient Network's router) have no problem connecting to the lan or internet and have no problem connecting to any of the printers. When I put the powerbook on that switch, I could not connect to the internet - i.e. whether connecting via the lynksys switch or direct with the efficient networks router - same results: no internet connection whether manually or via DHCP.
    So the imac G5 has no problem with the efficient networks router but the powerbook G4 hits a brick wall. The G4 likes the D-Link router. I am concerned (and I will have to check this) that if I turn off the dhcp server feature from the D-Link, that whatever software issue crops up between the powerbook and the Efficient Networks router, will rise up again, because the D-Link will act like a simple switch (just like my linksys switch), and we'll be back to square zero. In any case, no harm in trying. This may be the cause of the Powerbook not seeing that Brother printer (even though it sees another printer and other macs).
    Having spent hours reading about network problems, I think it's safe to say that macs have problems with certain routers. Why a G5 works and a powerbook G4 doesn't is beyond me, but clearly software must play a role.

  • Can't connect via Screen Share or Web Server, but can ping and ssh

    Bit of an odd problem here.
    My Mountain Lion Mac Pro (called "Trogdor" for convenience) is connected to my work university network. I can ping it from anywhere-- elsewhere on the network, from home behind a firewall. Can connect over ssh from everywhere. I can also connect to other computers (on the same network or at home behind a firewall) from Trogdor via ssh, Screen Sharing, etc.
    But I can't Screen Share into Trogdor, and I can't connect to Trogdor's built-in web server, either system-wide (in /Library/WebServer) or for my username (~/Sites). (I can connect to the web server from Trogdor.)
    Note that I can do both of these for other computers on the same network (same subnet, etc), so it's not a network issue. I can't do these from anywhere: same network or from home. I have this problem whether I use Trogdor's hostname or its IP address. (I can look up its hostname using the IP address with the "host" tool in Terminal, and vice versa.)
    So it sounds like a port issue, right? Except I don't think I've ever messed with my port settings directly. How do I diagnose the problem? Should I scan my ports? Can I return port settings to default?
    Thanks!
    Message was edited by: supercres

    Bit of an odd problem here.
    My Mountain Lion Mac Pro (called "Trogdor" for convenience) is connected to my work university network. I can ping it from anywhere-- elsewhere on the network, from home behind a firewall. Can connect over ssh from everywhere. I can also connect to other computers (on the same network or at home behind a firewall) from Trogdor via ssh, Screen Sharing, etc.
    But I can't Screen Share into Trogdor, and I can't connect to Trogdor's built-in web server, either system-wide (in /Library/WebServer) or for my username (~/Sites). (I can connect to the web server from Trogdor.)
    Note that I can do both of these for other computers on the same network (same subnet, etc), so it's not a network issue. I can't do these from anywhere: same network or from home. I have this problem whether I use Trogdor's hostname or its IP address. (I can look up its hostname using the IP address with the "host" tool in Terminal, and vice versa.)
    So it sounds like a port issue, right? Except I don't think I've ever messed with my port settings directly. How do I diagnose the problem? Should I scan my ports? Can I return port settings to default?
    Thanks!
    Message was edited by: supercres

  • Can I connect my AirMac Extreme like this? (It doesn't seem to work)

    Is this the right discussion area? I couldn't find one titled "AirMac Extreme".
    Anyway, I got an AirMac Extreme the other day and want to connect it via ethernet to my existing non-wireless router, set a fixed IP address manually (like I do with my iMac, since I have 8 fixed IP addresses) and then use it to provide DHCP services to wireless computers at home (like I do now with Internet sharing from my iMac G5).
    First my MBP just couldn't see the base station at all - even though my iMac G5 and PBG4 could. After 2 hours on the phone with Apple they suggested changing the channel. When I changed it to 9 then at least my MBP could see the Base Station and I could set it up with the new Airport Utility. (I am curious why the MBP couldn't see it until I changed the channel while my other two Macs could...)
    After I changed the channel and set it up, I can connect to the network I create.
    But I can't connect to the Internet.
    Apple support was friendly friendly, but the guy seemed sort of clueless. The manual seems to indicate that I can do that sort of setup, but I can't get it to work.
    Any suggestions?
    Thanks,
    doug

    Is
    this the right discussion area? I couldn't find one
    titled "AirMac Extreme".
    "AirMac" is the term Apple uses in Japan for
    "AirPort". You are in the correct area.
    Well, that explains that mystery. I live in Tokyo and bought my AirMac Extreme at Yodobashi Camera in Shinjuku.
    When I changed it to 9 then at least my MBP
    could see the Base Station and I could set it up with
    the new Airport Utility. (I am curious why the MBP
    couldn't see it until I changed the channel while my
    other two Macs could...)
    If your MacBook Pro was a US model, it can only use
    channels 1 to 11. Japanese Mac models can
    use channels 1 to 14. When the AirPort
    Extreme base station (AEBS) is set to automatic
    channel selection it tends to pick a high channel. If
    the AEBS was a Japanese model it probably picked
    channel 14.
    And another mystery. I bought my MBP from the U.S. Apple Store while in the U.S. in December. I wonder why the US models have less channels.
    The manual seems to indicate that I can do
    that sort of setup, but I can't get it to
    work.
    The setup you describe sounds fine and should
    work.
    Do you have any type of MAC
    address filtering (access control) enabled on your
    non-wireless router? If so, you need to add the
    Ethernet MAC address of the AEBS to the list of
    allowed clients.
    Since you are using fixed IP
    addresses, does your ISP record the MAC addresses of
    allowed computers? If so, you need to add the
    Ethernet MAC address of the AEBS to the list of
    allowed clients.
    Since you didn't elaborate
    much on the failure, it is possible that it is a DNS
    issue. To determine this, use the information in KB 106798, Mac OS: Troubleshooting "A
    connection failure has occurred", "The specified
    server could not be found" or Similar
    Messages.
    My ISP does not record the MAC addresses of allowed computers. I've re-used some of these fixed IP addresses before with different computers over the last few years.
    There is no MAC address filtering on the non-wireless router.
    I tried manually adding the DNS server IP addresses to the setup, so that didn't help. Also, in terminal, I couldn't ping an address, and that doesn't make use of the DNS anyway.
    I think it must be the setup itself. There are various options I'm not familiar with. Should I have the "bridge off" set or should it be set to "distribute IP addresses", etc...
    Thanks!
    doug

  • Can't Connect via XP

    I've just installed my new Airport Extreme N base station and updated both the software and firmware for the unit. I have a sold green light on the front of it, so it appears everything was updated properly.
    I connect my Mac (this computer) via ethernet to the base station, and it all works. However, I can't seem to connect my Windows XP (SP2) computer, located in a different room, wirelessly. This computer connected fine to my old Linksys router (with no security settings enabled).
    I was trying to configure my wireless network with maximum security to prevent anyone else from connecting to it.
    I have it set up to use WPA/WPA2 Personal wireless security.
    On the Windows XP computer, I use a Linksys Wireless G USB adaptor (WUSB54Gv2). Using the Linksys setup utility (visible in the task bar), I created a New Profile and entered in my security settings. It can see the Airport Extreme basestation, and says it's connected to it. However, it can't connect to the Internet.
    Short of disabling all security on my new Airport Extreme (and throwing out a main reason for getting it), what can I do to get my Windows XP computer to access the internet?

    Well, I guess the hex equivalent question is a moot point now, as I've got the network running securely via WPA2 now.
    To do so, though, I purchased and installed a new wireless adapter for my Windows XP computer. I bought a Netgear WN121T Wireless-N USB adapter.
    At first, I had the same problem I had with my Linksys wireless G USB adapter...it could connect to the Airport Extreme, but not to the internet. I tried the hex equivalent thing by entering it in the password box, but got nothing.
    Then...I checked Netgear's web site and found a newer software installation version, Version 5. Configuring everything thru Netgear's Wizard (including entering the password into the WPA2 box) worked like a charm this time.
    My connection speed is a much-improved (but still not ideal) 130Mbps (compared to the 54Mbps I was able to get with my wireless G adapter). I'm guessing this is because the adapter doesn't operate in the 5GHz range...only 2.4GHz.
    At any rate, my connection is now faster than before....and secure.

Maybe you are looking for

  • Stroke effects not exporting to PDF from CS3

    Hi, I'm using CS3 on Windows XP. My problem is that some stroke effects are not showing up in PDFs. On a two page document, the effects on page one do not show up on the PDF but the effects on page two show up perfect. I've tried multiple export pres

  • Transfered contacts not appearing in address book.

    Verizon Wireless transfered the contacts from my old phone to my new BB8330.  The contacts are not appearing in the business or personal folder.  Previous numbers I had dialed that were in my old contacts now have the contact name attached and when I

  • Not in iTunes

    My ipod is not recognized in iTunes, when plugged in it says "please wait very low battery" and shows a sad face every minute or so, none of the troubleshooting worked

  • Regarding queryString in jsp

    Hi, In my application, im sending emails and in that im giving link to one of my webpage. Along with the link im passing one name as a query string. Using JavaMailAPI im setting the mail content like this MimeBodyPart mbp1 = new MimeBodyPart(); mbp1.

  • PLEASE HELP!! ORACLE/ORANT/FORMS

    HELLO I AM FROM ATHENS GREECE I HAVE NO IDEA FROM ORACLE AND FORMS BUT I MUST SAVE AND OPEN FILES FROM A CRASHET PC FROM A CUSTOMER. WITH NTFS FILES BACKUP I HAVE SAVE THIS FILES ON C: oracle: admin ora92db oradata orant and ROTA: AKINITA.fmx FISPROS