SQL & PL/SQL :: Verifying Database Connection From External Java Process?
Apr 11, 2013Is there any way, in Oracle where I can find out if there is any process from some machine which has been successfully connected database ?
View 5 RepliesIs there any way, in Oracle where I can find out if there is any process from some machine which has been successfully connected database ?
View 5 RepliesWhich is the best driver for java to Oracle database connection ?
View 1 Replies View RelatedI am trying to invoke program from my local Windows machine (exactly java executor, which is in my environment on c:javajdkinjava) using database package with Java stored procedure.
Everything is fired by SQLPLUS script, this script invokes package with Java stored procedure (jar loaded into Oracle) and that procedure is trying to invoke runtime process (syntax:
c:javajdkinjava -cp
and here ara my classes and main jar) using my local java executor. I added all permissions using dbms_java.grant_permisions (execution forced me to give permissions java.io.FilePermission to <<ALL_FILES>> for execute), moreover I added to my database user JAVASYSPRIV and JAVAUSERPRIV role. Unfortunately, beside this I am still getting error:
C:javajdkinjava not found (Note that lookup with PATH isn't done due to the oracle executable being setuid.)
I Program with Java . when we connect oracle by program ,
Get the following error :
'No suitable driver found for jdbc:orcl:thin:@localhost:1521 '
I am using Oracle 11g database. The situation is I need to run a batch process a fixed intervals and copy data into my table from a remote database using a DB Link. I have 3 tables,1. Original data Table, 2. Exported data Table, 3. Status table. All the data from the remote database will be loaded into the exported data table. As and when each copying is finished the status table will be updated with 'Y' if export is success and with 'N' if export is unsuccessful. When the exporting is over, then status table is checked, if all the status' is Y then the data from Exported data table will be copied into the Original data table after truncating all the rows of Original data table. If the status is N then the Original data table will be intact.
How to check whether the exporting was success for all the exported data ? what to do if the connection through the DB Link was lost during the exporting?
In my application, we are getting the following exception on calling the Java procedure.
java.sql.SQLException: ORA-29532: Java call terminated by uncaught Java exception: java.lang.OutOfMemoryError
ORA-04030: out of process memory when trying to allocate 10804020 bytes (joxp heap,f:OldSpace)
[Code].....
I have a requirement to extract data from an XML formatted string that is passed as an IN parameter to a database stored procedure. I do not have a table to store the XML, nor an XML schema, nor a namespace, just the XML string. While new to XML, I do understand the basics. Using XMLTable I am able to parse out the simplest of XML data. My problem is this; attempting to extract data from nested XML nodes results in the error
'ORA-19279: XQuery dynamic type mismatch: expected singleton sequence - got multi-item sequence'.
Testing a solution example I found on this site by Barbara Boehmer, I still get the ORA-19279 error. I suspect it may be because I have version 10g while she has version 11g. Her solutions is from #msg_514154. Here is that code that gives me the error:
SCOTT@orcl_11gR2> SELECT x."deptno"
2 FROM (SELECT '<departments><deptno>1</deptno><deptno>2</deptno></departments>' col FROM dual) xml_data,
3 XMLTABLE
4 ('/departments/deptno'
5 PASSING XMLTYPE (xml_data.col)
6 COLUMNS
7 "deptno" number path '/deptno') x
8 /
deptno
----------
1
2
2 rows selected.
As I said, this example generates the ORA-19279 error. Need processing XML data from an IN parameter?
I have a java application (jdk 6) that use a db oracle 11g with ojdbc6.jar version 11.2.0.1.0 on linux.
Sometimes (one or two cases on 11k sql insert on table in one day) I obtain, the error:
java.sql.SQLRecoverableException I/O Error: Connection reset
at oracle.jdbc.driver.T4CStatement.executeForDescribe(T4CStatement.java:866)
at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:1145)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1259)
oracle.jdbc.driver.OracleStatement.executeQuery(OracleStatement.java:1469)
oracle.jdbc.driver.OracleStatementWrapper.executeQuery(OracleStatementWrapper.ja
va:389)
...
This error keeps on comming in my welogic forms server window many often....can any one tell me why it is so ?
<Error> <oracle.forms.servlet> <FRM-91230> <fatal
error in runtime process: timeout on connection to Java client>
I am using Http URL Connection class to post a data to a URL (which is a web service). The web service accepts data as text / XML.
Following is the code snippet i used:
URL url = new URL("http://xxx.xxx.xx.xx:8080/SampleWebService.svc");
HttpURLConnection conn =(HttpURLConnection) url.openConnection();
conn.setDoOutput(true);
conn.setRequestMethod("POST");
[code].....
But when i execute the code, I am getting following error at the line(InputStream in2 = conn.getInputStream()wink.gif
java.io.IOException: Server returned HTTP response 400 for URL
We have a daily batch job executing a oracle-plsql function. Actually the quartz scheduler invokes a java program which makes a call to the oracle-plsql function. This oracle plsql function deletes data (which is more than 6 months) from 4 tables and then commits the transaction.
This batch job was running successfully in the test environment but started failing when new data was dumped to the tables which happened 2 weeks ago (The code is supposed to go into production this week). Earlier the number of rows in each table was not more than 0.1 million. But now it is 1 million in 3 tables and 2.4 million in the other table.
After running for 3 hours, we are getting a error in java (written in the log file) "...Connection reset; nested exception is java.sql.SQLException: Io exception: Connection reset....". When the row-counts on the tables were checked, it was clear that no record was deleted from any of the tables.
Is it possible in oracle database, for the plsql procedure/function to be automatically terminated/killed when the connection is timed out and the invoking session is no longer active?
i need access to a view running on another database server. i configured my db link and tried to compile the view. but the following message occurs: ora-12154: TNS: Connection Identifier..
View 16 Replies View RelatedHow to write a code(procedure) to connect external database through PLsql coding.. I mean,
first, "Create connection like connection string", then "retrieve data from tables inside the database".
For external tables does not require any database space.But where the external tables are storing.
View 3 Replies View RelatedI want to stored the excel or ms word document in oracle database. Is it possible to view that file from database. If i export full database it is included in that dmp.
View 5 Replies View RelatedI have an issue with the text area column(Column name-Text) while interfacing the data from oracle database to external system.The data in database is saved as:
This is test entry for commentfield.
testing the script
Pre-production
23-FEB-2012
We want all the line breaks to replaced with a space or a comma. to implement this i have used to simple select as :
Select Replace(text,chr(10),'')
From paymemo
where referencepkey = (select pkey from paymain where ID = 'DED-520074 505354DN6 2012-02-04 00:06:48');
This is not working because of type conversion issues.
i want to know the backend process of Oracle DB.because when ever we are taking about DB , so many things are coming into pictures like Physical,logical structures,instance,schema,servers,storage and all. Actually i know what is oracle and why we are using that .
View 4 Replies View RelatedOracle 11g default server process is dedicated select distinct server from v$session; dedicated
Which server process is used in the oracle 11g Production? if the database is connect to an online application?
Currently maximum process is set to 150 in one of the RAC database. What should we do if the current session is about to reach maximum process or has exceeded the max process.
View 7 Replies View RelatedI'm trying to install Oracle10g in win7 Home premium. It is installing but problem is when installation process trying to create database on the system, a message is appearing which telling that ORA-12546:TNS:permission denied.
View 1 Replies View RelatedI have an issue with an Oracle 9 database where I can connect if I do not specify a database to connect to but when i do specify one i get an error. For example, my database is called WEB. If i open sqlplus and type connect username/password it will connect fine. If I type connect username/ password @web I get an error.The full error that appears in the log is:
TNS-12500: TNS:listener failed to start a dedicated server process
TNS-12546: TNS:permission denied
TNS-12560: TNS:protocol adapter error
TNS-00516: Permission denied
32-bit Windows Error: 5: Input/output error
I have checked the tns entries and listener file and both are fine. Here are the entries:
TNSNAMES:
WEB =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = web)
)
)
[code]....
I have just installed Oracle Forms 11g with the Weblogic web server. I have a local installed database, and access to our network databases also.
I can do a TNSPING and get valid results back from that. I can connect with SQL Plus, and SQL Devloper. However, I cannot connect with the Forms 11g Forms Builder. where to copy the TNSNAMES.ORA file for use with Forms 11g?
We are in the process of setting up a DR environment for our SAP and Oracle databases . The netapp and our architects came up with solution as follows .
1.Standby databases are built for all production databases.
2.The SAP file systems are replicated to the secondary site
3.The Oracle logfiles and controlfiles are replicated by netapp snap mirror every 10 mins interval
4.The database is recovered through recover standby database every 15 mins at standby site
5.Please note there is no data guard involved .
6.To test the failover , the mirror is broken .The standby controlfile is replaced with Production controlfile and Redo logs files.
7.The standby database issued a startup comnmand and it worked .
Would like to know whether the step 6 is a correct approach ? I tried to convince the architects that this will result in a very disastrous situation for us but none is listened to .
I have got a procedure that successfully creates an oracle external table and populates it with the contents of a file. This works fine until I have a situation where one of the fields is a VARCHAR2(2) and I try to insert say, a 5 character value. When this happens the record in question does not get populated in the external table (and rightly so), but I could do with working out if there is a discrepancy in the number of records in the file and the number of records that actually make it into the table so I could inform the user that there is a problem.
I have attached the code that creates the external table and populates it.
I have 3 questions.
I have 11.2.0.1 database on Windows 2008 R2 SP1.
1) While connecting to the database as sysdba (sqlplus "/as sysdba"), it takes about 12 to 15 seconds what things I need to check/change so that connection will be faster?
2) Also, I have read somewhere that changing the sga/memory parameters connecting to the database. is it true?
3) This is not concerned with above 2 questions. What should be the memory parameters size for a 8 gb database?
What I have is:
Total System Global Area 1068937216 bytes
Fixed Size 2182592 bytes
Variable Size 1027605056 bytes
Database Buffers 33554432 bytes
Redo Buffers 5595136 bytes
Our database is on one site . There is a form which is used by users on another site. The internet connection is lost sometimes and the form that they use looses connection to the database. What I would like to do on the form is whenever the connection is lost to the database i,eORA-03114,I want to reestablish the connection so that the form can be used by users all the time.
View 1 Replies View RelatedThe problem i mentioned in my last posting "CRS installation/PRIF-10: failed to initialize the cluster registry" was due to the fact i was using Redhat Linux 9 that seems to have some missing packages. I installed White Box RH 3 and everything worked fine.
if it's possible to connect to a 10g RAC database using the jdbc java thin client. the java thin client requires an ip, and database sid. I am running a two node cluster and i have two ip's and a service name that uses TAF option.
I´m just having a problem whit the connection between Oracle Forms 6i and Oracle Database 11G. Is just when i login to the database schema i cant log in using Forms.
TNS Names its already configured, No problems when i log in using Toad and using the TNS Names from Developer's 6i tool. I can log in just when i change the schema(user) password from the database (thats the rarest thing) and log into the application.
So whenever i want to login to the application i must to change the schema password, i need to use it directly.
Toady i have installed oracle forms 10g and oracle 10g db when i run my form it gives me this error how can i resolve it
"ora-12154 tns could not resolve the connect identifier specified"
View the image below:
Here are the values in forms 10g tns
# tnsnames.ora Network Configuration File: C:DevSuiteHome_1
etworkadmin nsnames.ora
# Generated by Oracle configuration tools.
EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
[code].......
and here the values of forms 10g SQLnet
# sqlnet.ora Network Configuration File: C:DevSuiteHome_1
etworkadminsqlnet.ora
# Generated by Oracle configuration tools.
SQLNET.AUTHENTICATION_SERVICES= (NTS)
NAMES.DIRECTORY_PATH= (LDAP, TNSNAMES, EZCONNECT, ONAMES, HOSTNAME)
(description =
# (address=(protocol=tcp)(host=localhost)(port=1383))
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
(connect_data=(rpc=on))
)
What changes should i make to overcome this problem.
I am gettting error message databse connection closed itried
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.
[code]...