Home Answers Viewqa JDBC Problem with url in oracle

 
 


Suvo
Problem with url in oracle
0 Answer(s)      a year and 2 months ago
Posted in : JDBC

hi i m having trouble with the following 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>
<head>
<title>check</title>
</head>
<body>

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
 <%@ page import="java.sql.*"%>
 <%@page import="java.io.*"%>
 <%String m=null;
  String m1=null;
  String s=request.getParameter("t1");
  PreparedStatement ps=null;
  Connection cn=null;
  ResultSet rs=null;
  Class.forName("oracle.jdbc.driver.OracleDriver");
  cn=DriverManager.getConnection("jdbc:oracle:thin@127.0.0.1:1521","system","tiger");
  ps=cn.prepareStatement("select * from emp where name=?");
  ps.setString(1,s);
  rs=ps.executeQuery();
  while(rs.next())
    {
      m=rs.getString(1);
      m1=rs.getString(2);
      }
      out.println("Emp id :" +m);
     out.println("Name :" +m1); 
    %>    
    </body>
</html>
View Answers









Related Pages:
Problem with url in oracle
Problem with url in oracle  hi i m having trouble with the following 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> <
URL problem
URL problem  Hi. I have created a webpage for my project website. in that i have used frameset to split the page. Now if i click any link in the page its navigating to the another page. but the problem is here in the url its
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
problem with dynamic url
problem with dynamic url  Hello! I was asked to implement a dynamic url code below to a html template I designed. I am a web designer... it right. Can't figure out why there is a space in the path on the "$t_url
oracle connectivity problem with netbeans
oracle connectivity problem with netbeans  sir I am using oracle window version +net bean6.8. jam trying to connect net bean to oracle. for this after adding new driver(ojdbc6.jar) in services tab I got connectivity with oracle
jdbc oracle connectivity problem
jdbc oracle connectivity problem  Hi All, I am trying to connect my swing application to oracle DB . but class.forname is giving error. Please suggest me if there is some different way to connect swing application to oracle
Oracle 9i database problem
Oracle 9i database problem  Hi Somebody has given the solution but i.............,send reply immediately. I have a problem in Oracle9i .I have installed Oracle 9i in my laptop.and i got sql+ page ok.i have gone to control panel->odbc
how to solve this problem for oracle connectivity
how to solve this problem for oracle connectivity  Exception in thread "main" java.sql.SQLException: Io exception: The Network Adap ter could not establish the connection
ex. connect to Oracle - Java Beginners
"; String db = "XE"; String url = "jdbc:oracle:thin:@" + serverName... to oracle, please give me a details tutorial with example code how to connect to oracle. what software i must to use? thank's   Hi
java oracle connection problem - SQL
java oracle connection problem  I have successfully made connection with the oracle10g database that i am using and also able to put in data using JSP. But the codes that i have tried for fetching the data are not working even
Assigning URL
Assigning URL  Actually i have created an attendance template, i can use it perfectly, now the problem is how can my team members access... url to my attendancetemplate.jsp file, please help me if anyone knows, am
Preventing URL rewriting
. Mow the problem is after the user has logged in he/she copies the url. after logged out if he/she rewrites the url then it is redirecting to the same page has...Preventing URL rewriting  Hi. I have a login in page. After the user
Preventing URL rewriting
. Mow the problem is after the user has logged in he/she copies the url. after logged out if he/she rewrites the url then it is redirecting to the same page has...Preventing URL rewriting  Hi. I have a login in page. After the user
Oracle - Java Beginners
Oracle   Hi sir, I installed oracle but the error occur on The java Runtime Environment was not found, at bin\jrew.exe. Hence the Oracle Universal Installer can not be run JRE version 1.1.7 Are the Java and Oracle related
struts url problem in Switching module using SwitchAction class - Struts
struts url problem in Switching module using SwitchAction class  when i use SwitchAction class,it creates a problem take a examle when i go from my login module to admin module it shows the url of login module
Oracle Database connectivity probem
Oracle Database connectivity probem  hi Below is the code of oracle... also set the environment variable like that .;E:\oracle\ora81\jdbc\lib\classes12.zip;E:\oracle\ora81\jdbc\lib\ojdbc14.zip;C:\Program Files\Apache Software
Problem with open connection - Hibernate
Problem with open connection  Hi Team, I am running one hibernate application and the database is ORACLE 10g.I am getting the below error.I connected to the database by using JDBC(with same driver and url).Please tell me
creating a friendly url for web application
creating a friendly url for web application  Hi all, I don't know how to create a friendly url for a web application. Please help me to resolve this problem. Thanks, Suresh
coding problem - Java Beginners
coding problem  hi! i declared date as date datatype in oracle now i..."; String url = "jdbc:mysql://localhost:3306/test"; String GET_RECORD...=DriverManager.getConnection(url, "root", "root"); stmt
Oracle Database error - JDBC
Oracle Database error   String query11 = "SELECT product_code, product_quantity, price FROM o"+orderid; ResultSet rs11... where is the problem?  Hi Friend, Try the following code: import
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
store the image in the oracle using blob and get it back - JDBC
store the image in the oracle using blob and get it back  hi i am facing problem in the following code . this code can store the image in table...("oracle.jdbc.driver.OracleDriver"); Connection conn = DriverManager.getConnection("jdbc:oracle:thin
PHP Variables from URL
PHP Variables from URL Are you facing problem passing PHP variable from URL...; But sometime it will create problem for you to show your information in the URL. How see... one thing if you are passing unnecessary information in the URL is fine
Java file to url
Java file to url In this section, you will learn how to convert file to url... mark, then the problem will occur as this method just appends "file:/".... To overcome this problem, you can use the following code: File.toURI().toURL
pagination problem - JSP-Servlet
= "oracle.jdbc.driver.OracleDriver"; String url = "jdbc:oracle:thin:@twtesting:1550:orcl1...(),my problem is that where i have to put & how to do pagination? my code...(className); connection = DriverManager.getConnection(url, user, pwd
pagination problem - JSP-Servlet
= "oracle.jdbc.driver.OracleDriver"; String url = "jdbc:oracle:thin:@twtesting:1550:orcl1"; String user...(),my problem is that where i have to put & how to do pagination? my code... = DriverManager.getConnection(url, user, pwd); statement
jsp with database oracle
this problem <%@ page import ="java.sql.*" %> <%@ page import ="java.util.
jsp page connectivity with oracle - SQL
connectivity jsp with oracle. Please send the code for solving problem. thanks  Hi Friend, 1)Import the packages: 2)Load the oracle driver...: a) If you are using oracle oci driver,you have to use: Connection connection
REQ for connection b/w jdbc and oracle database
REQ for connection b/w jdbc and oracle database    REQ for connection b/w jdbc and oracle database    The Java classes to connect to Oracle are contained in the Oracle JDBC driver jar file. For recent releases
Oracle9i Problem
Oracle9i Problem  Hi I have a problem in Oracle9i .I have installed Oracle 9i in my laptop.and i got sql+ page ok.i have gone to control panel... the Oracle and it tested successfuly.Now i clicked on SQL+ and i typed " scott
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
how to read data from excel file through browse and insert into oracle database using jsp or oracle???
then you can change the JDBC Driver and the url according to Oracle. http...how to read data from excel file through browse and insert into oracle database using jsp or oracle???  sir.. i have number of excel sheets which
jsp problem
jsp problem  Hello Friends, I want to show one page for 5 seconds and after that i want to redirect the page to another URL
connectivity problem
connectivity still i am facing this error* ================================oracle...=DriverManager.getConnection("jdbc:oracle:thin:@127.0.0.1:1521:XE","HR","HR
solve this problem
is compiled but when i eneterd url in tomcat server. Its not giving error but only... in table please tell me the solution for thid problem import java.io.*; import... = response.getWriter(); String url = "jdbc:mysql://localhost/zulfiqar?user
Servlet problem
problem from last three month and now i hope rose india developers... connectivity code it works but problem is with servlet page. My servlet code... = 0; /* String url= "jdbc:jtds:sqlserver://db205.my-hosting-panel.com
URL Encoding and URL Decoding
URL Encoding and URL Decoding  What is URL Encoding and URL Decoding ?   URL encoding is the method of replacing all the spaces and other extra characters into their corresponding Hex Characters and Decoding
jsp problem
jsp problem  problem:::::::: On JSP form ,when i insert data in text...(value){ xmlHttp=GetXmlHttpObject() var url="getdata.jsp"; url=url+"?name="+value; xmlHttp.onreadystatechange=stateChanged xmlHttp.open("GET",url,true
problem in database
problem in database   thanks for web site. I want change this code to insert data into PostgreSql database using jsp,servlets. but i getting...; &lt;url-pattern&gt;/*&lt;/url-pattern&gt; &lt;/servlet
insert excel value in to oracle data base
insert excel value in to oracle data base  Hi All I am using this code for saving excel value to oracle database table. code is working properly... this Excel file then how excel data will mapp to oracle database table. My project
java programming problem - JDBC
java programming problem  Hi, Request you to provide the source code in Java for the following programming problem : upload .csv file data into oracle database. please send the solution to raichallp@yahoo.in
How can I get the full URL with the attached parameters? - JSP-Servlet
How can I get the full URL with the attached parameters?  Hi, I'm trying to figure out how to get the current url and use it in my jsp page. I... parameters. For example if the url of the JSP page is: http://localhost
i have problem with classnofounderror
i have problem with classnofounderror   import java.sql.*; public class Tyagi { public static void main (String args[])throws SQLException... = DriverManager.getConnection("jdbc:oracle:thin:@localhost:8080:oracle", "System", "manager
i have problem with classnofounderror
i have problem with classnofounderror   import java.sql.*; public class Tyagi { public static void main (String args[])throws SQLException... = DriverManager.getConnection("jdbc:oracle:thin:@localhost:8080:oracle", "System", "manager
problem with the installation of apache-geramio2.1 server
problem with the installation of apache-geramio2.1 server  i have installed Apache Geronimo 2.1 server on my pc,but desired page is not coming on the BROWSER after typing localhost:8080 on the contrary oracle page
Jdbc connectivity in java to oracle for retrieving data between two dates
Jdbc connectivity in java to oracle for retrieving data between two dates ... dates from the database table. I am using combo box to get the date. Problem... am using the oracle. please help. thankyou sir
Friendly URl
Friendly URl  creating a SEO friendly URL
Multi-Date Handling Problem
Multi-Date Handling Problem  In our project we are using Oracle 10g as our data base, the problem is that we are picking In-date & Out-date from a calendar and on the basis of that date we are checking that on that date some
Code Problem - Struts
Code Problem  i want to insert multiple row values (from html table which is in jsp) into oracle database using struts.for example oracle table contains 3 fields as sub1,sub2,sub3.html table contains 10 rows of sub1,sub2,sub3
Unable to connect servet, jsp to oracle 10g database.. Unable to retrieve data..
= driver=oracle.jdbc.driver.OracleDriver url=jdbc:oracle:thin:@192.168.100.20...Unable to connect servet, jsp to oracle 10g database.. Unable to retrieve data... = DriverManager.getConnection(aProps.getProperty("url"), aProps.getProperty("duser

Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.