vedha vas

Greenhorn
+ Follow
since Jul 22, 2008
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by vedha vas

I have a simple query.
Will they p12 file contain more than one certificate chain with different aliases.?
16 years ago
Am running a Update query.
dynamically am setting the parameters ( columns) and its values in the prepared statement.

Finally when am giving a executeUpdate its returning zero and when i run the same query in the oracle its updating the datas.
The executeUpdate() Method is returning zero for a update query.
Which when we execute it oracle works fine and updated the data.
The parameters set in the query are all correct.
Can anyone please help me? why the executeUpdate() returns zero?
Hi Shriya Kishore ,

Try this way :

String s[] = {new String("1"),new String("2"),new String("3"),new String("4"),new String("5")};
String str = Arrays.asList(s).toString();
System.out.println(str.substring(1, str.length()-1));
16 years ago
Hi Sindura Kapur,

The follwoing are the mistakes i noticed:

1. The String hello was not ended properly.

String s= "hello" ;

2.The sysout was not proper.

System.out.println(a[i]);

3.The local variable(i) wat you inside the for loop.Its life or visibility is only within the for loop
you cant refer it outside.

4.Try this way:


(or)



[edit]Add code tags. CR[/edit]
[ July 24, 2008: Message edited by: Campbell Ritchie ]
16 years ago
Hi Nandhini Sruthi ,

Try this way,

String url = "c\\documentsandsettings\\user\\privatefiles\\get_url.txt";
int dotCnt = url.indexOf(".");
String str = url.substring(0, dotCnt);
int slashCnt = str.lastIndexOf("\\");
String filename = str.substring(slashCnt+1);
System.out.println(filename);
16 years ago
Hi Rajat Bhatnagar,

In the DBConnect class you already have a field for Connection connection.
Then in the DBConnection method why again you are creating a connection variable.
Just use the above.

Code to be modified:



[Added code tags - Dave]
[ July 24, 2008: Message edited by: David O'Meara ]
Hi Mandar Khire ,

Try this way:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<%
for(int i=0 ; i<=10 ; i++){
out.println(i+"<br>");
}
%>
</body>
</html>
16 years ago
JSP
Hi Rajkumar balakrishnan ,

In the checkSession method, in the try part first call the valueBound(event) method after that start
with the code:
ps=con.prepareStatement(SQL2);
ps.setString(1,sname);
Hi Rajkumar balakrishnan,

The problem is with the con.Con is null.
The connection is not estabilished thats why its throwing NPE.
Pl post the dbModel.java class also so that we can find out how you are estabilishing the connection.