Use Scan Name In Tnsfile - Not Able To Connect To DB Through JDBC Connection?
Aug 4, 2010
I have installed 2 node RAC -11gR2 on ORACLE VM Server 2.2.1.now, I want to give tnsentry to my dev team to use this RACDB going forward.I am using scan name in tnsnames.ora file. Also I have make scan name entry in /etc/hosts not in the DNS.
I have below entry in RACDB server...
RACDB =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = RWCORA-cluster-scan)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = racdb)
)
now just for testing purpose, I added this tnsentry in my machine to check the connectivity.I have to add scan name with IP address in /etc/hosts --. and try to connect sqlplus sys@rwcdb as sysdba --> not workingI have to add scan name with IP address , and two RAC VIPs (of both nodes) in /etc/hosts -- and try to connect sqlplus sys@rwcdb as sysdba --> then its working...but again SQL*Developer is not able to connect.
I have make below entry in my machine's /etc/hosts file:
10.40.0.51 RWCORARAC1-vip
10.40.0.52 RWCORARAC2-vip
10.40.0.50 RWCORA-cluster-scan
perfect link through which I can connect OCI, JDBC connection from client side.
View 4 Replies
ADVERTISEMENT
Aug 21, 2013
I am not able to connect to ORACLE ODA 11g. but using sqlplus its getting connected with below credential.
URL------------------- jdbc:oracle:thin:sacblmdbuser/sacblmdbuser@10.66.12.229:1521:OVPINHA
Oracle JDBC driver loaded ok.
Unable to create connection
java.sql.SQLException: Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=186647296)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
View 2 Replies
View Related
Mar 30, 2005
The 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.
View 5 Replies
View Related
Jul 18, 2012
I connection to TimesTen as follow:
String url = "jdbc:timesten:direct:dsn=my_ttdb";
String username = "ADMINISTRATOR";
String password = "";
Connection connection = DriverManager.getConnection(TestTT.url, TestTT.username, TestTT.password);
I wonder if this JDBC Connection is a TCP/IP connection on the backend? If this is not a TCP/IP connection, how can I make a connection with TimesTen via TCP/IP protocol?
dsn:my_ttdb configuration likes:
[my_ttdb]
Driver=/home/tttest/TimesTen/tt1122/lib/libtten.so
DataStore=/home/tttest/ttdata/database/my_ttdb
LogDir=/home/tttest/ttdata/logs
PermSize=40
TempSize=32
DatabaseCharacterSet=ZHS16GBK
OracleNetServiceName=orcl
View 12 Replies
View Related
Sep 25, 2013
how to set connection property "oracle.jdbc.thinLogonCapability"
View 3 Replies
View Related
Jan 11, 2005
I'm trying to connect to multiple Oracle 10g databases (failover) over the JDBC thin client, and when I run the following, I get: java.sql. SQLException: Io exception: NL Exception was generated
connection = DriverManager.getConnection("jdbc:oracle:thin:@DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (HOST = dbdev) (PORT = 1521))) (CONNECT_DATA = (INSTANCE_NAME = orcldev)))", "scott", "tiger");
I eventually want to put multiple ADDRESSes in that string, but right now I'm trying to get it to work with just one! I've tried multiple variations of this, like changing INSTANCE_NAME to SID or SERVICE_NAME, and using the internal IP address for the HOST dbdev (see below). Here's the tnsnames.ora file used by SQL*Plus on the same client machine:
ORCLDEV.world =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.132)(PORT = 1521))
(CONNECT_DATA =
(SID = orcldev)
)
)
View 7 Replies
View Related
Jul 17, 2013
have a problem while i am trying to connect to database through JDBC here is my code,i am using oracle11g express edition import java.sql.
Connection;import java.sql.DriverManager;import java.sql.SQLException;import java.sql.Statement; public class connectiontoDB { public static void main(String[] args) throws Exception { // TODO Auto-generated method stub try{ Class.forName("oracle.jdbc.driver.OracleDriver"); Connection con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:ORCL","citi","citi"); Statement stmt=con.createStatement(); stmt.executeUpdate("create table user(id number(10))"); System.out.println("connected to database successfully"); } catch(Exception e){ e.printStackTrace();
View 1 Replies
View Related
Feb 21, 2013
The problem is that this connection errors when I try to connect using my SQuirreL client. My developers want to connecting using the SID or the SERVICE_NAME and by using the "New Method" syntax, not the "Old Method" syntax. According to the documentation the "New Method" syntax works with the SERVICE_NAME or the SID. The "Old Method" only works with the SID.
# Host name is vmwwin7634.na.SAS.com
# SID is sting2
# SERVICE_NAME is sting2.na.sas.com
PROBLEM using SID errors ==> jdbc:oracle:thin:@vmwwin7634.na.SAS.com:1521/sting2
THIS WORKS using SERVICE_NAME ==> jdbc:oracle:thin:@vmwwin7634.na.SAS.com:1521/sting2.na.sas.com
I am using SQuirreL Client version 3.4.0
# Here is the tnsnames.ora entry on the server.
STING2 =
(DESCRIPTION =
[code]...
# In this documentation it says, "On new syntax SERVICE may be a oracle service name or a SID."You can find this on the orafax wiki under JDBC#Thin_driver.
# I was able to connect with the "old method" using the SID only, SERVICE_NAME errors jdbc:oracle:thin:@vmwwin7634.na.SAS.com:1521:sting2.na.sas.com
(SQuirreL client error, "Unexpected Error occurred attempting to open an SQL connection.")
jdbc:oracle:thin:@vmwwin7634.na.SAS.com:1521:sting2 (this works)
# "New Method"
jdbc:oracle:thin:@vmwwin7634.na.SAS.com:1521/sting2.na.sas.com (this works)
jdbc:oracle:thin:@vmwwin7634.na.SAS.com:1521/sting2 (this errors)
(SQuirreL client error, "Unexpected Error occurred attempting to open an SQL connection.")
View 10 Replies
View Related
Apr 9, 2013
We are using oracle 11.2.0.3.0 with 3 node rac. Earlier 3 scan vip and 3scan listener running on each node.But we found recently node1 running using 2vip and 2scanlistener and in node2 1vip and 1scanlisteners were running.but no longer running scan vip or scan listener in node 3. If i decided to reloacate the scan vip/Scan_listener to node3 from ndoe 1 using below command,does it cause any impact on my transcation?
$ srvctl relocate scan -i 2 -n node03
$ srvctl relocate scan_LISTENER -i 2 -n node03
find the below details
$ bash
bash-4.2$ srvctl status scan
SCAN VIP scan1 is enabled
[Code]....
View 12 Replies
View Related
May 12, 2011
when i am connecting to my database in command prompt,sql * plus editor is it successfully connecting to the database but not connecting with the oracle client OEM.
but after connecting the LAN it is not connecting and also in the case when i am connecting to the internet through the USB datacard it is not connecting with the oracle client OEM.
how can i connect to database when the LAN,USB datacard connection.
View 1 Replies
View Related
Jul 23, 2012
I have sample windows C# application to connect remote Oracle DB(Enterprise edition SQ L plus).
Want to connect remotely without installing oracle client on local system.
View 13 Replies
View Related
Oct 26, 2010
I have this box that runs a dataguard observer in a test lab.
Is there a way to configure connect time failover and connection timeout in the connect identifier used by DGMGRL? It does not seem to respect the parameters I supply.
This is what I used for TNSNAMES connection string:
DB=
(DESCRIPTION =
(ADDRESS_LIST =
(FAILOVER=ON)
[Code].....
When the hosts are up, if the instance is not running, I really get a quick reply from DGMGRL. However, when some host is not available, it can take quite a while to get an answer, minutes..
=
I though I could use
(TYPE=select)
(METHOD=basic)
(RETRIES=5)
#(DELAY=1) # defaults to 1 when retries is set
in the connect_data section, but this does not seem to have an effect
=
I also tried ' (CONNECT_TIMEOUT=5)' in the ADDRESS_LIST section
=
So assuming that Oracle NET services are not available on the hosts. What can I use to make 'dgmgrl' report that it can't connect to the host quickly ? Should I look into the TCP timeout parameters ?
View 1 Replies
View Related
Dec 23, 2009
I am connecting to Oracle 9i using JDBC in my JSP/Servlets web pages. I am closing all my connections in Finally blocks.
Everything works great during the day with JDBC and Oracle.But after a Web crawler runs through our web server at 3 AM the next morning a v$session check shows several lines of JDBC Thin Client inactive status. find exactly what sql statement or program that could be causing the JDBC Thin Client to show up?
View 1 Replies
View Related
Jan 29, 2013
I'm using PreparedStatement to execute a query with some parameters. in sql developer, it just spends 12 seconds but in jdbc, it's around 140 seconds.
I disabled "_optim_peek_user_binds" parameter already but it didn't work. alter session set "_optim_peek_user_binds"=false;
View 1 Replies
View Related
Jul 28, 2013
How to know the version of Oracle and JDBC of remote databases that is accessing my database through DBLInk.
For example I have a database A , B database is using my database Through a dblink.Now I want to know the version of oracle and jdbc which working on B.
View 4 Replies
View Related
Jul 29, 2013
Since JDK 6, DatabaseMetaData.getCrossReference contract is :Retrieves a description of the foreign key columns in the given foreign key table that reference the primary key or the columns representing a unique constraint of the parent table (could be the same or a different table). But the Oracle JDBC Driver executed query is :
SELECT
NULL AS pktable_cat,
p.owner as pktable_schem,
p.table_name as pktable_name,
pc.column_name as pkcolumn_name,
[code]...
View 0 Replies
View Related
Dec 10, 2012
Here are the relevant tables to the triggers I'm having trouble with.
create table profile
(
userID number(10),
uname varchar2(64),
email varchar2(32),
password varchar2(32),
date_of_birth date,
[code]...
Here's the triggers I currently have that doesn't work.
create or replace trigger DropAccount
after delete on profile
FOR EACH ROW
BEGIN
delete from groupMembership where (userID = :old.userID);
END;
The DropAccount trigger's purpose is to delete all the records from groupMembership that contains the userID of the person deleting his/her own account. It appears to work when I run the following statements in sqlplus:
delete from profile where (userID = '1');
select * from groupMembership where (userID = '1');
But when I try to delete an account through a java interface using JDBC I get the following error:
Machine Error: java.sql.SQLException: ORA-04091: table *****.GROUPMEMBERSHIP is mutating, trigger/function may not see it
ORA-06512: at "*****.DROPACCOUNT", line 2
ORA-04088: error during execution of trigger '*****.DROPACCOUNT'
The java function basically just executes a delete statement.
View 1 Replies
View Related
Jun 27, 2013
java.sql.SQLException: ORA-04054: database link GMAIL.COM does not exist
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:331)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:288)
at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:743)
at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:207)
at oracle.jdbc.driver.T4CStatement.executeForRows(T4CStatement.java:946)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1169)
at oracle.jdbc.driver.OracleStatement.executeUpdateInternal(OracleStatement.java:1615)
at oracle.jdbc.driver.OracleStatement.executeUpdate(OracleStatement.java:1580)
at com.jdbc.pack.Lab1.main(Lab1.java:31)
View 7 Replies
View Related
Apr 21, 2010
Upgrading from 10.1.0.2 to 10.1.0.5. Enterprise Manager requires 'newest' version of Oracle JDBC drive.Downloaded what I believe to the correct file (classes12.jar). I'm unclear what to do with this, my readings have pointed me in the following direction:
1) copy to c:oracleproduct10.1.0db_1jre1.4.1in
2) extract
here is the problem...tried:
1) just clicking on it (nothing)
2) c:program filesjavajre1.6.0_03injavaw -jar classes12.jar
Error:
Failed to load Main-Class manfest atrribute from
c:oracleproduct10.1.0db_1jre1.4.1inclasses12.jar
Is my location correct, I've been hunting everywhere..making no progress.
View 4 Replies
View Related
Jul 7, 2012
I have been troubling with this issue for the last two weeks...tried so much, but could not able to resolve....
sqlplus username/password@IPAddress:port/ServiceName
I am able to connect to DATABASE from SQLAssistant only when I provide string like ABOVE........If I dont mention the SERVICE, m unable to connect to DB.Now the biggest issue is with SQL Developer.....m not at all able to connect to DB using SQL Developer.
View 3 Replies
View Related
Aug 17, 2010
I have installed oracle developer 6i. in sqlplus i want to put my username and password but nothing in the connect string field.
View 1 Replies
View Related
Oct 6, 2010
I have the following computer/setup:
Acer laptop, Intel Processor w/ Windows 7 Professional (64-bit)
Delphi 2010 Professional
Oracle XE (+ the Oracle XE client that comes with it)
I cannot can't to the Oracle database from Delphi. The error I keep getting is:
Alias is not currently opened. [Oracle][ODBC][Ora]ORA-12154:TNS: could not resolve the connet identifier specified.
Here's what I've done:
1. Create an ODBC connection to my Oracle database
- run C:WindowsSysWOW64odbcad32.exe to open the ODBC administrator.
- Data source name: bt_user
- TNS Server Name: localhost/xe
- user bt_user
- Clicked "test connection" -- Success.
2. Open Delphi and drop a TDatabase component on my main form.
- Set the Alias Name property to "bt_user" (the alias I set up in ODBC)
- Set database name to "bt_user".
- Checked "connected".
Alternatively, I tried using the Delphi ADO components (the dbGo components).
- Drop TADOConnection component on my form.
- Select "connection string" and open the dialog.
- Click "build string".
- Select "Microsoft OLE DB Provider for ODBC Drivers" from the selection.
- In "use data source", select "bt_user" from the drop-down list (my ODBC connection from #1)
- Click "test connection".
Again the same error.
My questions are:
1. Can Delphi work with Oracle XE (Express Edition)?
2. If so, then do I need to install the "Instant Client"?
3. Will the instant client for Oracle 10g work with Oracle 10g XE?
4. Do I need to install any additional ODBC driver(s)?
5. Why was I successful in creating the ODBC connection in Windows, but it failed in Delphi?
6. Will Visual Studio.NET (C#) work with Oracle XE, and what are the steps for setting that up?
View 2 Replies
View Related
Jun 24, 2013
We are going to setup a 4 node rac cluster. So i think we need to configure only one SCAN with 3IP's. And how the scan listeners are configured on these 4 nodes.
View 1 Replies
View Related
Sep 1, 2011
I am planning to install oracle RAC 11g R2 on RHEL 5.3. I have 2 RAC nodes and one openfiler NAS. I need to understand how will I configure SCAN IP. Do I need to configure it some where in DSN and OS level or just I need to give this IP and SCAN name while grid install and oracle will create these things?overall steps to configure this or direct me to some documentation where this thing is detailed.
View 6 Replies
View Related
May 21, 2013
We have an application where delete statement is taking a long time ( 30-40 seconds).v$session_longops shows the sql statement is doing a full table scan. The statement is "delete tablename where column_name =:B1". The table is indexed and the indexed column is being used in the where clause. When I do an explain plan on the same statement with a value for column_name, it uses an index scan. The table has 9 million rows and the delete statement deletes 15 rows. Not sure why SQL when running through the application does not use index. The stats are current.
View 11 Replies
View Related
Nov 17, 2012
if i have local index, does query which uses this index always have to scan all partitions?
For example, I have hash-partitioned table on column A. There is local index on column B. I am querying:
select * from my_table where A='ABC' and B>123.
I know that records with A='ABC' are in 2nd partition. Does only 2nd partition of local index will be scanned or all of them must be scanned?
View 1 Replies
View Related
Aug 18, 2012
I�m Using Oracle 11.I have a table with 16 million rows and an index (let's call it the employee table with an index on department). I need to select all the employees whose departments are located in the uk. I achieve this by selecting all the department numbers from departments where location = 'UK' in a sub select then plug this into the main query as follows:
SELECT *
FROM employees
WHERE department IN (SELECT department from departments where location = 'UK');
It takes ages, 25 seconds or more, the explain plan shows its doing a full table scan on emplyees. I need it to use the index. The sub query is instant and returns only 5 rows. If I explicitly put the 5 numbers in the IN clause the query uses the index and executes in 0.04 seconds. See below:
SELECT *
FROM employees
WHERE department IN (1,2,3,4,5);
I need it to use the subquery once and then use the index on the main table.
View 2 Replies
View Related
Jul 8, 2012
I need to create a form that will enable me to scan pages and save it into a specified folder using the scanner connected to the PC.
View 1 Replies
View Related
Dec 19, 2011
I want to make full table scan of my query so that I can execute it using parallel option & the query will get completed in few mins. Even though I used this hint "/*+ parallel(t2,4) full(t2) */, the query is executing with 8 parallel processes but it is going for "Rowid Range Scan" and it is taking more time to complete. How to make this query to go for full table scan instead of "Rowid Range Scan" so that this query can be tuned.
SELECT /*+ parallel(t2,4) full(t2)*/ID, COUNT (1) FROM acnt_transact t2 GROUP BY ID;
View 9 Replies
View Related
Sep 19, 2010
scan image from Oracle Form Builder 6i and store the image location in the oracle 9i database. Here important issue is we just store the image location in the database not the image. We'll store the images in a storage device and store the location path in the database. And retrive the image from storage device using the path.
For example: User Scan the image using Form builder 6i then save the image like 1001-DPS-1.jpg in the default location like D:Image.. And in oracle 9i database data save like : 1001 DPS 1 D:Image1001-DPS-1.jpg User_Name Sysdate
Data save automatically in the database when image scanned and saved in physical drive. This is our main purpose.
Is it possible to solve this task using Oracle 9i and Developer 6i?
View 2 Replies
View Related