Home Answers Viewqa JDBC i have installed oracle 10g (both ee and xe) editions... while am installing i found port num as 1521 for ee, 1522 for xe

 
 


kalyanitokuri
i have installed oracle 10g (both ee and xe) editions... while am installing i found port num as 1521 for ee, 1522 for xe
0 Answer(s)      2 years ago
Posted in : JDBC

i have installed oracle 10g (both ee and xe) editions... while am installing i found port num as 1521 for ee, 1522 for xe.... and my program is......
import java.sql.*;
import java.io.*;
public class DBConnect{
public static void main(String ar[])throws SQLException{
DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
System.out.println("driver is registered");
Connection con=
DriverManager.getConnection("jdbc:oracle:thin:@localhost:1522:xe","lms","xyz");
System.out.println(con);
System.out.println("connection is established");
Statement stmt=con.createStatement();
ResultSet rs=stmt.executeQuery("insert into emp values(3,'c')");
while(rs.next()){
int eno=rs.getInt("eno");
System.out.println(eno);
String name=rs.getString("name");
System.out.println(name); 
}
}
}...... while i run this prog.... i got error like
driver is registered
oracle.jdbc.driver.T4CConnection@929206
connection is established
Exception in thread "main" java.sql.SQLException: ORA-00942: table or view 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(OracleStateme
nt.java:1169)
        at oracle.jdbc.driver.OracleStatement.executeQuery(OracleStatement.java:
1273)
        at DBConnect.main(DBConnect.java:12)

E:\jdbcex> 
and in sql i have create user lms and, table emp(eno, name).
please tell me wts the resolution for this problem....
View Answers









Related Pages:
i have installed oracle 10g (both ee and xe) editions... while am installing i found port num as 1521 for ee, 1522 for xe
i have installed oracle 10g (both ee and xe) editions... while am installing i found port num as 1521 for ee, 1522 for xe  i have installed oracle 10g (both ee and xe) editions... while am installing i found port num as 1521
prablems on oracle ee installation in windows7 ultimate(32 bit).
prablems on oracle ee installation in windows7 ultimate(32 bit).  Hai i have face several prablems when ever i m install oracle ee in my system(32 bit)windows7 ultimate.it is not installed in my system.can any body help me how
i am getting the problem when i am downloading the pdf file from oracle 10g database - Struts
i am getting the problem when i am downloading the pdf file from oracle 10g database  if i created the pdf file from pdf machine,it is storing into datbase and download the pdf file from database. but when i created the pdf file
i need a school appication using struts frame work with oracle 10g using myeclipse6.0
i need a school appication using struts frame work with oracle 10g using myeclipse6.0   hi i need a school apllication using struts frame work backend 10g xe using myeclipse 6.0
tables in oracle 10g
tables in oracle 10g  sir i have created a table in oracle 10g,i want to know where this table is stored and how can i move this table to another pc and insert values
storing date from html form to oracle 10g using servlet
storing date from html form to oracle 10g using servlet  i have... this date month year from html form into oracle 10g database where i have..."); con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:XE","ORS
storing date from html form to oracle 10g using servlet
storing date from html form to oracle 10g using servlet  i have... this date month year from html form into oracle 10g database where i have..."); con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:XE","ORS
oracle problem
oracle problem  Hi I have installed oracleXE on my system and for reasons i've uninstalled them and am not able to stop oracle xe services and i could'nt reinstall it. I couldnt reinstall my os for this as it is in my office
The app was not installed on iphone because its resources have been modified
The app was not installed on iphone because its resources have been modified  Hi, I am getting following error while my client is installing my AdHoc build on his iPhone: "The app was not installed on iphone because its
hi .. need help ASAP ..i have a project buit in eclipse , i have installed jasper. i want the steps to work on it ..
hi .. need help ASAP ..i have a project buit in eclipse , i have installed jasper. i want the steps to work on it ..   hi .. need help ASAP ..i have a project buit in eclipse , i have installed jasper. i want the steps to work
Error in jdeveloper 10G
[Oracle Application Server Containers for J2EE 10g (10.1.2.0.0...) My program is giving the following errors,i am using Jdeveloper and struts and JSP I have used following: AddressAction.java import
Cookie in Java EE 6
. Example : Here I am giving a very simple example of cookie which...Cookie in Java EE 6 In this tutorial you will learn about the changes made in Cookie in Java EE 6. Cookie is an information that contains in a text form
android connection to database oracle 10g
android connection to database oracle 10g  Hello, How i can connect my android application to my oracle 10g database
Unable to connect servet, jsp to oracle 10g database.. Unable to retrieve data..
=oracle Let me know what is the duser and dpass.. ? I have created a new user...Unable to connect servet, jsp to oracle 10g database.. Unable to retrieve data..  I have a class file AbstractDataAccessObject with the below code
i have problem with classnofounderror
i have problem with classnofounderror   import java.sql.*; public... = DriverManager.getConnection("jdbc:oracle:thin:@localhost:8080:oracle", "System", "manager... student"); while(rs.next()) System.out.println
i have problem with classnofounderror
i have problem with classnofounderror   import java.sql.*; public... = DriverManager.getConnection("jdbc:oracle:thin:@localhost:8080:oracle", "System", "manager... student"); while(rs.next()) System.out.println
what is difference b/w oracle 8i, 9i and 10g
what is difference b/w oracle 8i, 9i and 10g  what are the difference between oracle 8i,9i and 10g? I am not considering the versions and their supported os, in the interview point of view
Tomcat not supporting Oracle 10g - WebSevices
Tomcat not supporting Oracle 10g  While Starting my Tomcat Server am... of Oracle version(Oracle 8i to Oracle10g). SEVERE: End event threw exception... time=16/47 config=C:\Tomcat 4.1\bin\..\conf\jk2.properties
error in uploading image from jsp to oracle 10g database
error in uploading image from jsp to oracle 10g database  java.sql.SQLException: ORA-01460: unimplemented or unreasonable conversion requested when i try to insert into the image into the database i got the above error
oracle - JDBC
oracle  HI i am using ORACLE 10g. How to i find "TNSNAMES.ORA" file in my system after installation of ORACLE 10g succussfully. please send to me answer. i know my port number is 8080 and some other data but i want
SQLException caught: No data found
SQLException caught: No data found  i m using ms office 2010, n when i run my source code it is giving error SQLException caught:No data found, plz help me why i am getting this exception, thanks alot, my source code
Am i convetrting the code right ? - Java Beginners
(PortInUseException ex) { } I have a device on the serial port which has a led on it. The LED blinks on the C#'s code. I think the code i have written...Am i convetrting the code right ?  C# private void button
i have got error while compiling simple tag handler
i have got error while compiling simple tag handler   javac.servlet.jsp not found! tell me what are the jar files required to run simple tag handler class   The package you have used javac.servlet.jsp does not exist
Insert or retrieve image into oracle 10g by using java
Insert or retrieve image into oracle 10g by using java   How can i insert or retrieve image into oracle10g using java plz i need it urgently,need guidance to do this plz
i have problem in that program - JavaMail
i have problem in that program  1. Write a multi-threaded Java program to print all numbers below 100,000 that are both prime and fibonacci number... read both the pipes to identify numbers common to both.. 2. Develop
Am using windows xp os..how to install wamp server for this os ?i have a trouble in this..
Am using windows xp os..how to install wamp server for this os ?i have a trouble in this..  i installed wamp server . i was put my wampserver is online.. but i cant open phpmyadmin in my browser. i dont know the reason.. pls
I don't found in Tomcat 7.0 's bin folder..
I don't found in Tomcat 7.0 's bin folder..  While making servlet using tomcat 7.0, i don't find startup.bat file in bin folder. My servlet... know how to run my servlet even i am following all the steps
Could not establish the connection to oracle - JDBC
at java.sql.DriverManager.getConncetion at inserttest.main I am using ORACLE 10.2.0 enterprise edition.When i installed oracle i changed password:puppy.My database is working is fine...Could not establish the connection to oracle  Hi Friends, I am
http 404 resource not found error
http 404 resource not found error   Sir, I have downloaded your RichLRApplication and deployed on tomcat 6 with oracle backend. Application started in tomcat manager. But when I try to run I am getting http 404 requested resource
Problem with url in oracle
code. when i run it i get the error as invalid oracle url specified. i am using tomcat 6 and oracle 10g release2 10.2.0.3. heres the code <html> <...=DriverManager.getConnection("jdbc:oracle:thin@127.0.0.1:1521","system","tiger"); ps=cn.prepareStatement
oracle
oracle   sir now am doing one project , my frond end is vb and backend is oracle. so 1> how can i store the image in my field 2> how can i back up the table into .txt file
sir i,have a assignment for these question plz help me sir - JavaMail
sir i,have a assignment for these question plz help me sir  ... test() { System.out.println("I am a bus"); } } class Car extends Vehicle{ void test() { System.out.println("I am a car"); } } class Bike extends
I am getting error.How can i get details
I am getting error.How can i get details  Exception in thread "main" java.sql.SQLException: Listener refused the connecti n with the following error... descrip or The Connection descriptor used by the client was: Localhost:1521:orcl
Installing Java
Installing Java      .... As a beginner, we consider that neither you don't have the java development kit... version of the JDK. Just by clicking the link ensure that your computer have
Ethernet port in java - Java Beginners
Ethernet port in java  Hello, I am new to this field. I have to make an web application in JSP in which i have to decode the packets received on ethernet port. I have no idea how to program the ethernet port in java and read
ex. connect to Oracle - Java Beginners
to oracle. what software i must to use? thank's   Hi..."; String db = "XE"; String url = "jdbc:oracle:thin:@" + serverName...ex. connect to Oracle  dear sir, I want to ask how to connect java
I am from .net background, I want to learn SOA.
I am from .net background, I want to learn SOA.  Hi I am from .net background, I want to learn SOA. Could it possible for me to learn SOA, I suppose SOA includes Java. I dont have knowledge of java. Please help Thanks  
server with two port - Java Server Faces Questions
.The same thing I want to do with other client C2 (which is connected to 3133 port).I have to send multiple clients with both types C1 and C2 randomly to the server . I do not know how can I change the port between the two clients types I have
javax.servlet not found error
javax.servlet not found error  why iam getting javax.servlet error while running my servlet program...after setting the classpath also i am finding that problem
Oracle Books
Edge: "I enjoyed this book from the beginning 'til the end. The Oracle Edge... Oracle Application Server 10g Administrator Exam Guide A powerful... on the new Oracle 10g Application Server administration exam. Certification
Not sure what I am missing ? Any ideas?
Not sure what I am missing ? Any ideas?  import java.util.*; public...) { if(str.length()==0) return false; for(int i=0;i<str.length();i++) if (c==str.charAt(i)); return true
class not found error - JDBC
class not found error  thanks for your response. please clarify the following doubts. i am having the specified mysql connector jar file. where... soon.  Hi friend, I am sending you a link. I hope that this link
I am getting this exception
I am getting this exception   Exception in thread "main" org.hibernate.exception.GenericJDBCException: Cannot open connection at org.hibernate.exception.ErrorCodeConverter.handledNonSpecificException(ErrorCodeConverter.java
Oracle - SQL
Oracle  I have one .dmp file. I want to import this file into oracle 9i and oracle 10g. wat is procedure and stepts. thanks u  Open... D:\oracle\ora90\BIN\imp type this command if your are using oracle 9i
code save word file in 10g database - SQL
code save word file in 10g database  I am not having any idea to save the whole word document in Oracle 10g. Please help me.   Hi Friend... = DriverManager.getConnection ("jdbc:oracle:thin:@localhost:3306:test","root", "root
Dll issue while launching the application
Dll issue while launching the application  I am using one dll in my... getting after installing one msi . But in my application i have a requirement... message(e.g msi has not installed , code for this i have implemented in the main
oracle connectivity
oracle connectivity  con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:orcl","hr","hr"); i have error on above line when i tried...=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:orcl","hr","hr
I am new to programming and I am not sure what to do next? Any ideas?
I am new to programming and I am not sure what to do next? Any ideas? ...()==0) return false; for(int i=0;i<=str.length();i++) if (c==str.charAt(i)); return true; } // If userInputs
Installing axis2 eclipse plugin
generator and Service Archiver wizards. In this section we have installed... Installing axis2 eclipse plugin    Axis2 eclipse installation - Installing Axis2 plugin on Eclipse IDE In this section
OCI Connectivity For Oracle Plz Solve This Error
) { e.printStackTrace(); } } } ---> I found Error below how i can solve this error plz...OCI Connectivity For Oracle Plz Solve This Error  import java.io...."); con=DriverManager.getConnection("jdbc:oracle:thin