Home » Developer & Programmer » Forms » How to connect database from sql*plus to forms?  () 1 Vote
How to connect database from sql*plus to forms? [message #164054] Tue, 21 March 2006 08:57 Go to next message
malar_dm
Messages: 31
Registered: December 2005
Location: Chennai,India
Member
Hi 2 all,

This is very urgent… please help?

I m not able to connect database from sql*plus to forms.
While input the data as

username : malar
password : ****
database : oracdata

It shows error message stating "ORA - 12541 : TNS:no listener"


From my knowledge, I copied the tnsnames.ora file from database and paste it below the tnsnames.ora file of forms. I followed two steps. This will be as follows:

Step 1:

# TNSNAMES.ORA Network Configuration File: D:\oracle\orad2k\network\admin\tnsnames.ora
# Generated by Oracle configuration tools.

ORACLE9I =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = Local)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = oracle9i)
)
)


ORACDATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = home-malar)(PORT = 1521))
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = Oracdata)
)
)

INST1_HTTP =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = home-malar)(PORT = 1521))
)
(CONNECT_DATA =
(SERVER = SHARED)
(SERVICE_NAME = MODOSE)
(PRESENTATION = http://HRService)
)
)

EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
)
(CONNECT_DATA =
(SID = PLSExtProc)
(PRESENTATION = RO)
)
)

# TNSNAMES.ORA Network Configuration File: D:\oracle\ora92\network\admin\tnsnames.ora
# Generated by Oracle configuration tools.

ORACDATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = home-malar)(PORT = 1521))
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = Oracdata)
)
)

INST1_HTTP =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = home-malar)(PORT = 1521))
)
(CONNECT_DATA =
(SERVER = SHARED)
(SERVICE_NAME = MODOSE)
(PRESENTATION = http://HRService)
)
)

EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
)
(CONNECT_DATA =
(SID = PLSExtProc)
(PRESENTATION = RO)
)
)




Step :2

1. I applied lsnrctl control to start the listener in command prompt.
It shows starting tnslsnr: please wait…

Service OracleOracle_d2kTNSListener already running.
TNS-12536:TNS:operation would block
TNS-12560:TNS:protocol adapter error
TNS-00506:Operation would block
32-bit windows error:997:unknown error.

2. I applied tnsping command. It shows

Used parameter files:
D:\oracle\orad2k\network\admin\sqlnet.ora
D:\oracle\orad2k\network\admin\tnsnames.ora

Used TNSNAMES adapter to resolve the alias
Attempting to contact <DESCRIPTION= <ADDRESS_LIST=<ADDRESS=<PROTOCOL=TCP> <HOST=home-malar> <PORT=1521>>> <CONNECT_DATA = <SERVER =DEDICATED> <SERVICE_NAME = oracdata>>>
TNS-12541: TNS: no listener

3. I applied this command in command prompt.
C:\>netstat –a

TCP home-malar: 1521 home-malar.oracdata:0 LISTENING


It shows error stating

‘TCP ‘is not recognized as an internal or external command, operable program or batch file.


Please help…

Thanks in advance

With regards
Malar




Re: How to connect database from sql*plus to forms? [message #164145 is a reply to message #164054] Wed, 22 March 2006 00:12 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
You copied tnsnames.ora, but you should also copy SQLNET.ORA and LISTENER.ORA. This might help.
Re: How to connect database from sql*plus to forms? [message #164785 is a reply to message #164145] Sun, 26 March 2006 03:44 Go to previous messageGo to next message
malar_dm
Messages: 31
Registered: December 2005
Location: Chennai,India
Member
hi littlefoot,

Thanks for ur reply. I followed ur method i.e Coping sqlnet.ora and listener.ora file and paste it into tnsnames.ora file.

But, still it will not get connected.It shows error msg stating "ORA - 12541 : TNS:no listener".

Please help, i m not able 2 solve this problem.

It's very urgent.



Thanks in advance

malar.
Re: How to connect database from sql*plus to forms? [message #164790 is a reply to message #164785] Sun, 26 March 2006 06:03 Go to previous messageGo to next message
naveednt
Messages: 34
Registered: October 2005
Location: Karachi, Pakistan
Member
check that Oracle???????TNSListner service is started?
Re: How to connect database from sql*plus to forms? [message #164795 is a reply to message #164785] Sun, 26 March 2006 11:48 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
There's no purpose in copying text you found in sqlnet.ora and listener.ora INTO the tnsnames.ora - you'll get a mess in there. Those are three different files, each of them with its own purpose.

Therefore: go to \network\admin directory into which you installed database. Take those three files and copy them into the \network\admin directory of the Oracle Developer Suite.
icon5.gif  Re: How to connect database from sql*plus to forms? [message #166093 is a reply to message #164795] Tue, 04 April 2006 08:48 Go to previous messageGo to next message
malar_dm
Messages: 31
Registered: December 2005
Location: Chennai,India
Member
Hi littlefoot,

I m not solve this problem. I just explain the steps that I followed. pls do some needful.

The data’s contained in sqlnet.ora and listener.ora file in database is same as the data contained in sqlnet.ora and listener.ora in d2k.

So, I just copied the data’s contained in tnsnames.ora file in database and paste it below tnsnames.ora in d2k.

But it will not work.


I start the listener control in command prompt. It shows;

Oracle oracled2k: TNS listener already running.
TNS: 12536: TNS: Operation would block
TNS: 12560: TNS: protocol adopter error
TNS: 00506: Operation would block.
32 bit windows error: 997: unknown error.

I am not solve this problem.


Please help…

sorry for disturbing u.

Thanks
malar.


Re: How to connect database from sql*plus to forms? [message #166094 is a reply to message #164790] Tue, 04 April 2006 08:50 Go to previous messageGo to next message
malar_dm
Messages: 31
Registered: December 2005
Location: Chennai,India
Member
Hi

I m not solve this problem. I just explain the steps that I followed. pls do some needful.

The data’s contained in sqlnet.ora and listener.ora file in database is same as the data contained in sqlnet.ora and listener.ora in d2k.

So, I just copied the data’s contained in tnsnames.ora file in database and paste it below tnsnames.ora in d2k.

But it will not work.


I start the listener control in command prompt. It shows;

Oracle oracled2k: TNS listener already running.
TNS: 12536: TNS: Operation would block
TNS: 12560: TNS: protocol adopter error
TNS: 00506: Operation would block.
32 bit windows error: 997: unknown error.

I am not solve this problem.


Please help…

very urgent...

Thanks in advance
malar.


Re: How to connect database from sql*plus to forms? [message #166175 is a reply to message #166094] Wed, 05 April 2006 00:22 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Quote:

So, I just copied the data’s contained in tnsnames.ora file in database and paste it below tnsnames.ora in d2k.


Your problem is the 'below' that you did. You have to REPLACE the contents of the file, not duplicate them. Please search this forum for 'tnsnames' and 'ifile', preferably the second as it hits on some high quality threads.

David
Re: How to connect database from sql*plus to forms? [message #166176 is a reply to message #166094] Wed, 05 April 2006 00:23 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
MALARVANNAN,

Please don't repost the same contents twice, a 'thump' is good enough.

David
Re: How to connect database from sql*plus to forms? [message #166740 is a reply to message #164790] Sat, 08 April 2006 00:30 Go to previous messageGo to next message
malar_dm
Messages: 31
Registered: December 2005
Location: Chennai,India
Member
Hi

I m not solve this listener protocal error. Can u please help me.


I start the listener control in command prompt. It shows;

Oracle oracled2k: TNS listener already running.
TNS: 12536: TNS: Operation would block
TNS: 12560: TNS: protocol adopter error
TNS: 00506: Operation would block.
32 bit windows error: 997: unknown error.

I am not solve this problem.


Please help…

very urgent...

Thanks in advance
malar.
Re: How to connect database from sql*plus to forms? [message #166870 is a reply to message #166740] Mon, 10 April 2006 01:58 Go to previous message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
It is already running, try stopping it and then restarting it.

Google your error messages.

David
Previous Topic: master detail data block problem
Next Topic: PL/SQL COMMANDS FOR DEVELOPER 2000
Goto Forum:
  


Current Time: Fri Sep 20 06:50:48 CDT 2024