How to connect oracle9i in vc++10
I can't download occi for oracle9i, and our environment is vs 2010.
Configuration vc + + compiler environment, complied success。 but run it throw a error: ORA-12560: TNS: 协议适配器错误
in my pc, I can connect oracle server by pl/sql, jdbc...
what can I do?
vc++10 can't connect oracle 9i by occi ?
There is no OCCI libraries built using VS 2010 for Oracle 9i.
Is it mandatory that you use Oracle 9i Client only ?
Similar Messages
-
How to connect DataBase 9i with 10g Developer Suit
Hi Every body , how i connect
Oracle9i Enterprise Edition Release 9.0.1.1.1 DataBase with 10g Developer Suit ????
when i'm trying to run my program i just can run it for the first time :( . when i'm
trying to run it for the second time i receive this msg
<html> <head> ORACLE FORMS.</head>
<body onload="document.pform.submit();" >
<form name="pform" action="http://ABUKARAKI.AHU.EDU.LOCAL:8889/forms90/f90servlet" method="POST">
<input type="hidden" name="form" value="C:\Documents and Settings\Admin\Desktop\MODULE1.fmx">
<input type="hidden" name="userid" value="tt/tt@oracle">
<input type="hidden" name="obr" value="yes">
<input type="hidden" name="array" value="YES">
</form> </body></html>Create your forms working directory.
add that path to default.env
and also edit parameter in formsweb.cfg to point to you main form.
This way by default when you go to http://ABUKARAKI.AHU.EDU.LOCAL:8889/forms90/f90servlet it will open your main form.
From main form you can open your other forms. -
Who can explain how EJB connect to Oracle9i DB with DataSource?
I have taken 4 days into this problem. I am developing EJB with J2EE1.3 and Oracle9i DB, I can connect to DB in code with DriverManager. But I want to use DataSource to connect to DB. I failed, I can not get new way to resolve it when I after try to connect with javax.sql.DataSource, oracle.jdbc.pool.OracleDataSource and oracle.jdbc.pool.OracleConnectionPoolDataSource.
I have got different Exceptions when I coding different ways:
one is:
Caught an exception.
java.rmi.ServerException: RemoteException occurred in server thread; nested exce
ption is:
java.rmi.RemoteException: nested exception is: javax.ejb.EJBException: U
nable to connect to database. com.sun.enterprise.resource.JdbcDataSource; nested
exception is:
javax.ejb.EJBException: Unable to connect to database. com.sun.enterpris
e.resource.JdbcDataSource
java.rmi.RemoteException: nested exception is: javax.ejb.EJBException: Unable to
connect to database. com.sun.enterprise.resource.JdbcDataSource; nested excepti
on is:
javax.ejb.EJBException: Unable to connect to database. com.sun.enterpris
e.resource.JdbcDataSource
javax.ejb.EJBException: Unable to connect to database. com.sun.enterprise.resour
ce.JdbcDataSource
<<no stack trace available>>
the Other is:
Caught an exception.
java.rmi.ServerException: RemoteException occurred in server thread; nested exce
ption is:
java.rmi.RemoteException: nested exception is: javax.ejb.EJBException: U
nable to connect to database. makeConnection:Io Exception: Connection refused(DESCRIP
TION=(TMP=)(VSNNUM=150999297)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4)
))); nested exception is:
javax.ejb.EJBException: Unable to connect to database. makeConnection:Io
Exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=150999297)(ERR=12505)(ERROR_
STACK=(ERROR=(CODE=12505)(EMFI=4))))
java.rmi.RemoteException: nested exception is: javax.ejb.EJBException: Unable to
connect to database. makeConnection:Io Exception: Connection refused(DESCRIPTION=(TM
P=)(VSNNUM=150999297)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4)))); nes
ted exception is:
javax.ejb.EJBException: Unable to connect to database. makeConnection:Io
Exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=150999297)(ERR=12505)(ERROR_
STACK=(ERROR=(CODE=12505)(EMFI=4))))
javax.ejb.EJBException: Unable to connect to database. makeConnection:Io Exception: C
onnection refused(DESCRIPTION=(TMP=)(VSNNUM=150999297)(ERR=12505)(ERROR_STACK=(E
RROR=(CODE=12505)(EMFI=4))))
<<no stack trace available>>
My codes related are:
private void makeConnection() throws NamingException, SQLException {
try{
InitialContext ic = new InitialContext();
OracleConnectionPoolDataSource ocpds = (OracleConnectionPoolDataSource) ic.lookup(dbName);
PooledConnection pc = ocpds.getPooledConnection();
con = pc.getConnection();
}catch(SQLException ex){
throw new SQLException("makeConnection:" + ex.getMessage());
DriverManager.registerDriver(new oracle.jdbc.OracleDriver());
con = DriverManager.getConnection(
"jdbc:oracle:thin:@172.28.200.43:1521:shcd",
"lijun", "xiaotian"); */
public void setEntityContext(EntityContext context) {
this.context = context;
try {
makeConnection();
} catch (Exception ex) {
throw new EJBException("Unable to connect to database. " +
ex.getMessage());
I believe I set JNDI and config EJB right, because I can run it with Cloudscape DB all right.
who can tell me where is my WRONG, or tell me how to connect to Oracle9i DB?Hi Jhlijun,
I am facing the same problem at the moment. However, I am not using a pooled connection. The following is my code. I am trying to connect a stateless session bean to an Oracle 9i database with result being fed back to a jsp page.
package Test;
import javax.naming.*;
import java.sql.*;
import java.util.*;
import javax.ejb.*;
import javax.sql.DataSource;
import javax.sql.*;
public class TestSessionEJBbean extends java.lang.Object implements javax.ejb.SessionBean
String q="Select NAMETITLE,NAMEFIRST,NAMELAST from People where PeopleRSN<100";
protected boolean create() throws java.lang.Exception
return true;
public TestSessionEJBbean()
{ // EJB constructors don't have a server context.
private void unhandledEvent( String listenerName, String methodName, java.lang.Object event )
// method for interface javax.ejb.SessionBean
public void ejbActivate() throws javax.ejb.EJBException, java.rmi.RemoteException
// To Do
// method for interface javax.ejb.SessionBean
public void ejbPassivate() throws javax.ejb.EJBException, java.rmi.RemoteException
// To Do
// method for interface javax.ejb.SessionBean
public void ejbRemove() throws javax.ejb.EJBException, java.rmi.RemoteException
// To Do
// method for interface javax.ejb.SessionBean
public void setSessionContext( javax.ejb.SessionContext parm0 ) throws javax.ejb.EJBException, java.rmi.RemoteException
this._sessionContext = parm0; // generated helper code
// To Do
* Test Method
public String Test() throws javax.ejb.EJBException
return "Hi! I am the SessionEjbBean.";
* Session Context of this EJB.
* Set in 'setSessionContext()' before any 'ejbCreate()' is executed.
private javax.ejb.SessionContext _sessionContext;
* ejbCreate Method
public void ejbCreate() throws javax.ejb.EJBException, javax.ejb.CreateException
try {
create(); // This 'create()' is used for internal initialization.
catch( java.lang.Exception __e) {
System.err.println( __e.toString() + " " + __e.getMessage() );
// TODO: implement
* getDBConnection Method
public sun.jdbc.rowset.CachedRowSet getDBConnection() throws javax.ejb.EJBException
String testPrint = "Starting...";//Only to check output
Connection conn;
sun.jdbc.rowset.CachedRowSet crset=null;
try {
testPrint += "before new InitialContext()....";//Only to check output
InitialContext ic = new InitialContext();
DataSource ds = (DataSource)ic.lookup("java:comp/env/jdbc/coquit");
testPrint += "before ds.getConnection()....";//Only to check output
conn = ds.getConnection("coquit","coquit");
testPrint += "before conn.createStatement()....";
Statement stmt=conn.createStatement();
testPrint += "before stmt.executeQuery(....)";
ResultSet rset = stmt.executeQuery(q);
testPrint += "before new sun.jdbc.rowset.CachedRowSet()";
crset = new sun.jdbc.rowset.CachedRowSet();
testPrint += "before crset.populate(rset)";
crset.populate(rset);
rset.close();
stmt.close();
conn.close();
} catch (NamingException ne) {
System.out.println("TestSessionEJBbean::getDBConnection Naming Exception " + ne);
}catch (Exception e){
System.out.println(testPrint+"...TestSessionEJBbean::getDBConnectionException" + e);
System.out.println("\n\n");
e.printStackTrace();
return crset; -
Topic: Who can explain how EJB connect to Oracle9i DB with DataSource?
I have taken 4 days into this problem. I am developing EJB with
J2EE1.3 and Oracle9i DB, I can connect to DB in code with
DriverManager. But I want to use DataSource to connect to DB. I
failed, I can not get new way to resolve it when I after try to
connect with javax.sql.DataSource,
oracle.jdbc.pool.OracleDataSource and
oracle.jdbc.pool.OracleConnectionPoolDataSource.
I have got different Exceptions when I coding different ways:
one is:
Caught an exception.
java.rmi.ServerException: RemoteException occurred in server
thread; nested exception is:
java.rmi.RemoteException: nested exception is:
javax.ejb.EJBException: Unable to connect to database.
com.sun.enterprise.resource.JdbcDataSource; nested
exception is:
javax.ejb.EJBException: Unable to connect to database.
com.sun.enterprise.resource.JdbcDataSource
java.rmi.RemoteException: nested exception is:
javax.ejb.EJBException: Unable to
connect to database. com.sun.enterprise.resource.JdbcDataSource;
nested exception is:
javax.ejb.EJBException: Unable to connect to database.
com.sun.enterprise.resource.JdbcDataSource
javax.ejb.EJBException: Unable to connect to database.
com.sun.enterprise.resource.JdbcDataSource
<<no stack trace available>>
the Other is:
Caught an exception.
java.rmi.ServerException: RemoteException occurred in server
thread; nested exception is:
java.rmi.RemoteException: nested exception is:
javax.ejb.EJBException: Unable to connect to database.
makeConnection:Io Exception: Connection refused(DESCRIPTION=
(TMP=)(VSNNUM=150999297)(ERR=12505)(ERROR_STACK=(ERROR=
(CODE=12505)(EMFI=4)
))); nested exception is:
javax.ejb.EJBException: Unable to connect to database.
makeConnection:Io
Exception: Connection refused(DESCRIPTION=(TMP=)
(VSNNUM=150999297)(ERR=12505)(ERROR_
STACK=(ERROR=(CODE=12505)(EMFI=4))))
java.rmi.RemoteException: nested exception is:
javax.ejb.EJBException: Unable to
connect to database. makeConnection:Io Exception: Connection
refused(DESCRIPTION=(TM
P=)(VSNNUM=150999297)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)
(EMFI=4)))); nested exception is:
javax.ejb.EJBException: Unable to connect to database.
makeConnection:Io
Exception: Connection refused(DESCRIPTION=(TMP=)
(VSNNUM=150999297)(ERR=12505)(ERROR_
STACK=(ERROR=(CODE=12505)(EMFI=4))))
javax.ejb.EJBException: Unable to connect to database.
makeConnection:Io Exception: C
onnection refused(DESCRIPTION=(TMP=)(VSNNUM=150999297)(ERR=12505)
(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
<<no stack trace available>>
My codes related are:
private void makeConnection() throws NamingException,
SQLException {
try{
InitialContext ic = new InitialContext();
OracleConnectionPoolDataSource ocpds =
(OracleConnectionPoolDataSource) ic.lookup(dbName);
PooledConnection pc = ocpds.getPooledConnection();
con = pc.getConnection();
}catch(SQLException ex){
throw new SQLException("makeConnection:" + ex.getMessage());
DriverManager.registerDriver(new oracle.jdbc.OracleDriver());
con = DriverManager.getConnection(
"jdbc:oracle:thin:@172.28.200.43:1521:shcd",
"lijun", "xiaotian"); */
public void setEntityContext(EntityContext context) {
this.context = context;
try {
makeConnection();
} catch (Exception ex) {
throw new EJBException("Unable to connect to database. " +
ex.getMessage());
I believe I set JNDI and config EJB right, because I can run it
with Cloudscape DB all right.
who can tell me where is my WRONG, or tell me how to connect to
Oracle9i DB?Hi,
on small thing to check (or perhaps do):
Make sure that you are using the JDBC drivers from the Oracle9i
DB client e.g. copy the classes12.jar from the ORACLE_HOME of
the database client into OC4J_HOME lib.
Also, one thing that might help is to define an explict Oracle
datasource e.g.
- Set class to value of Oracle DataSource class
- Use only the location logical name
- Returns Oracle implementation of java.sql.Connection
<data-source
class="oracle.jdbc.pool.OracleDataSource"
name="jdbc/oracle/PooledDS"
location="jdbc/oracle/PooledDS"
username="scott"
password="tiger"
url="jdbc:oracle:thin:@<host>:<port>:<SID>"
/>
Andy -
How to connect sql server using oracle Client
Hi,
I am working in oracle9i and windows os 32 bit.
I need to connect SQL server 2000 from my oracle client..
I heard about heterogeneous connectivity ...
Please expalin me the steps what to add and how to connect the sql server...
Regs....Are you trying to connect to SQL Server from your Oracle database (i.e. create a database link in Oracle to SQL Server)? Or are you trying to connect to SQL Server using your Oracle client software (i.e. SQL*Plus)?
The former just requires Heterogeneous Services with Generic Connectivity. The latter is functionality that has been depricated and probably no longer works in your environment.
Justin -
How to connect Oracle database using TOAD Database toll
Hello ALL,
I have installed oracle 9i and TOAD in my machine.
I want to connect oracle9i using TOAD database toll.
How can i able to connect Oracle9i using TOAD database toll?What is the code i will change in tnsnames.ora so that i am able to connect scott/tiger database using TOAD?
tnsnames.ora*
SUMANTA.IN002.SIEMENS.NET =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = BLRD025AL1)(PORT = 1521))
(CONNECT_DATA =
(SERVICE_NAME = sumanta)
Please suggest.
Thanks for your time.
Regards,
Sumantauser2367151 wrote:
Hello ALL,
I have installed oracle 9i and TOAD in my machine.
I want to connect oracle9i using TOAD database toll.
How can i able to connect Oracle9i using TOAD database toll?What is the code i will change in tnsnames.ora so that i am able to connect scott/tiger database using TOAD?
tnsnames.ora*
SUMANTA.IN002.SIEMENS.NET =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = BLRD025AL1)(PORT = 1521))
(CONNECT_DATA =
(SERVICE_NAME = sumanta)
Please suggest.
Thanks for your time.
Regards,
SumantaIf you have a listener on host BLRD025AL1, and that listener knows about a service named 'sumanta', then you don't need to do anything to your tnsnames.ora to use it with Toad -- or any other client tool. You just have to provide the correct connect string.
What have you actually tried?
What result did you get?
Any oracle errors (ora-nnnnn or tns-nnnnn)? -
How to connect my friends apple notebook through video call
HOW TO CONNECT TO A FRIEND WHO IS USING APPLE NOTEBOOK FROM MY IMAC SUGGEST ME WAITING FOR A SOLUTION FROM APPLE TEAM SUPPORT
Hi,
Typing in all upper case is regarded and shouting here.
Presumably as you have posted in the OS X 10.7.x (Lion) area you are running this version of the OS on your iMac.
This will have iChat 6 on it.
This can use AIM, Jabber and Yahoo IDs within the app.
Apple IDS ending in @mac.com and iCloud issued @me.com and @icloud.com are also Valid AIM Screen Names.
If you use Googlemail and Enable "talk" in the products there you can then use your Google Mail ID as a Jabber ID (although it has it's own Add Account option in iChat)
Facebook has an option to Enable "Chat" which will give you a Chat ID variant on your name there and this can be used in iChat (or Messages) as a Jabber ID.
The Yahoo Account will only do Text chats.
It also has to be an actual ID registered at Yahoo.
Chats are then AIM to AIM or Jabber to Jabber or Yahoo to Yahoo.
So your Buddy will also need a suitable ID or Screen Name for the relevant service.
8:16 pm Sunday; January 19, 2014
iMac 2.5Ghz 5i 2011 (Mavericks 10.9)
G4/1GhzDual MDD (Leopard 10.5.8)
MacBookPro 2Gb (Snow Leopard 10.6.8)
Mac OS X (10.6.8),
Couple of iPhones and an iPad -
how to connect sound to my tv set using hdmi adapter. Im using 2009 macbook pro 13". I went to sound settings then output and it shows internal speaker built- in, it wont locate my tv set. pls. help, thanks
You probably can't because it looks like your MacBook Pro is too old to carry audio over HDMI. You will need to run a separate audio cable from the audio out port on the MacBook Pro to the audio in port on the TV.
Check your MacBook Pro model year against the list in this Apple tech note:
About Mini DisplayPort to HDMI adapters
Learn about the Mini DisplayPort in the latest Mac models that enables audio and video output for DisplayPort and HDMI. -
I need to know how to connect my macbook to the tv
I ordered the mini dvi adapter for my macbook 13in and obviously it connects to the computer but i have no idea how it connects to the tv. Where does it go? and do i need something else to help connect it to the tv? I am really confused please help.
Yep, Apple makes adaptors to go from the mini DVI on the macbook to almost any type of input that you TV will have. First check the back of your tube to find out what kind of input it has, and order the appropriate adaptor.
Luck
E -
How to connect a Sony Bravia TV to the internet through your Airport network
Since it took me a lot of time to figure out how to connect my Sony Bravia TV to the internet through my Airport network, I better share how to do it. Hopefully saving others a lot of time.
My 32EX600 Sony Bravia TV is Ethernet connected to my Mac Mini, which is part of my Airport network, together with another Mac, an Airport Extreme Base Station and an ADSL modem/router. Moreover, the Mac Mini is connected to the TV by HDMI.
Whatever I tried in the TV’s Wired Network Set-up (Auto, or Manual with manual IP, Subnet Mask, Default Gateway and DNS IPs), I couldn’t get it right. Cable Connection and Local Access were mostly OK, Internet Access always Failed.
The solution lies in the Sharing panel of the System Preferences of the Mac Mini. In the Internet Sharing item of that panel, you should choose to “share your internet connection from WiFi to computers (the TV in this case) using Ethernet“, and NOT (as I had chosen before and seemed so obvious) “share your internet connection from Airport to computers using Ethernet“. After that change, the Bravia Network Set-up, using the Wired and Auto options, flawlessly connected to the internet. No expensive (Sony) WiFi USB dongle needed.I have now had a detailed reply from Sony Europe and the way to do this is to:
1. Press Home on the TV Setup
2. Use the right and left arrow to select Setting.
3. Use the up and down to select Network, press Enter.
4. Select Network Setup.
5. Select Wireless setup.
6. Select Scan
7. Select your network
8. A new screen will appear asking for entering the security key.
9. Enter your WPA2 key.
10. Select Enter.
11. It will take you back to the same screen asking for entering the
security key.
12. Press the right arrow.
13. Select Auto.
14. Press the right arrow.
15. Select Save and connect.
These instructions are not the same as shown on the TV but they worked fine for me so they may help others with a similar problem. -
How to connect my Mac book Pro to a TV
How to connect my MacBook Pro to the TV using HDTV cable
I am assuming your TV has HDMI connector.
In that case, if your MacBook is the retina-one, you have HDMI connector there too. All you need is HDMI cable to connect teh two.
If your MacBook has thunderbolt port instead, you need Mini DisplayPort to HDMI adapter and HDMI cable.
Hope this makes sense. -
How to connect old aiport express to my new Airport Extreme?
I have a PC running with Win7 and just replaced my Jensen With a brand New Airport Extreme.
I have set up the Airport Extreme to the internet, Iphones and Ipads and it work as it should.
I have downloaded latest Version of Airport tool on my PC. In addition i have downloaded the airport tool for Ipad.
I have reset one of my airport Express and it now shows up both on the Ipad and on the PC airport tool.
My Ipad says "base station e5713b cannot be configured."
I have wired the airport Express to my Ethernet to be able to "see it" on my Airport tool.
My AirPort tool on the PC will not permit me to add the airport Express to my new Airport Extreme network (no network names on the drop-down list to choose from). I wished for an easy set-up, but nothing seems to be plug and play as the Commercial says.. can you please help me?
SigveHi
Thanks for Swift reply.
Yep - I in fact have two A1088 and one A1264
I actually bought the new router because the Jensen
router always lost connection to the Airport Express after some hours or days. I
always needed to restart my Jensen to play music and that was driving my wife
mad. The hope was that the Extreme should fix this. Both A1088 have been set up
to only stream music to two of my stereo amplifiers from my PC’s Itunes library.
Are the A1088 now useless?
The A1264 has been set up to feed internet into a Denon Reciever that needed Ethernet cable.
Please advise
Regards
Sigve -
How to connect my iPhone and iPad to Apple TV
How to connect my iPhone and iPad to Apple TV
Connect the iPad and Apple TV to the same WiFi network. Double Tab the home button on the iPad and then swipe your recently used apps from left to right until you see the mirroring icon which looks like a retangle with an up arrow. Tab that icon until you see the Apple TV. Tab Apple TV and slide the slider to the ON position. You should now see your iPad screen on the TV the Apple TV is connected to.
-
How to connect my ipod to itunes if my ipod is disabled and my top button is broken
how to connect my ipod to itunes if my ipod is disabled and my top button is broken
Place the iOS device in Recovery Mode and then connect to your computer and restore via iTunes. The iPod will be erased.
iOS: Wrong passcode results in red disabled screen
If recovery mode does not work try DFU mode.
How to put iPod touch / iPhone into DFU mode « Karthik's scribblings
For how to restore:
iTunes: Restoring iOS software
To restore from backup see:
iOS: How to back up
If you restore from iCloud backup the apps will be automatically downloaded. If you restore from iTunes backup the apps and music have to be in the iTunes library since synced media like apps and music are not included in the backup of the iOS device that iTunes makes.
You can redownload iTunes purchases by:
Downloading past purchases from the App Store, iBookstore, and iTunes Store -
How to connect my perfectly-working 20-year-old Apple Personal Laserwriter 320 to my iMac running Mountain Lion?
Thank you, Morty S.I have a perfectly-working LW 4/600 with exactly the same issue. They use localtalk - a long obsolete network connection, that doesn't connect to modern networks, and appletalk as the comm protocol.
I think the only choice you have is to use an old powerPC Mac as print server. You tell me which old Mac you have, with a localtalk connector, or that runs OS X 10.4 or earlier (so it speaks appletalk), and I'll tell you how I've done it for the past 11 years or so.
Right now I use a G4 running 10.4.11, plus an etherMac ethernet to localtalk adapter.
Before, I used a PMac 6100 running LPD server software.
Maybe you are looking for
-
Looking for a good alarm app that plays my songs
I was never a fan alarm clocks, the awful alarms they sounds are certainly no way to start the day. My CD radio alarm clock is slowly starting to pack in and I figure my iPhone4 can do the same thing. Can anyone recommend an alarm app that randomly p
-
New tabs added by Badi ME_GUI_PO_CUST not seen in ME21N and ME22N
Hi All I am implementing BADI ME_GUI_PO_CUST / ME_PROCESS_PO_CUST to add additional fields in Purchase Order Header. The implementation of the BADI ie the Subscreen of the fields to be added appears in Header of transaction ME23N but it does not app
-
Updating jpgs in Encore after editing in Photoshop
I have about 160 slides in an Encore Project - I edited a bunch in Photoshop and then reopened Encore. The jpgs were updated in the project window and in the slideshows but not in menu frames or when previewing - I rendered but still no luck - Then I
-
I'm using a networked linksys NSLU to house my music library and music files. When I plug in my iPod (video), it starts to synch immediately (I have it set to do this). The problem I see is that it takes forever >10 minutes to just even evaluate my 1
-
How to install an old version?
I`m have an issue with Premiere Pro CC and Pluraleyes, i read at this topic "Red Giant - PluralEyes: Odd synced timeline behavior after import? (Premiere Pro)" that this problem is because the last version of premiere. Now i want to instal the older