DrClap: PrepareStatement

If this is DrClap

First I thank you by the name of all the Java Forum

members.. your answers are great!!

Second, I have a problem:

I read early replys for the [two few parameters] problem and when I uesed the

con.PrepareStatement ( ) I recieve a :

Method PrepareStatement(java.lang.String) not found in

interface java.sql.connection

where is this method found?

TIA

Niema

[447 byte] By [NiemaOsman] at [2007-9-26 23:40:27]
# 1

Do youself a favour and get the JavaDocs for the JDK that you're using. It's an invaluable source of information that I use just about every day.

Anyway your problem is case. The convention in the JDK is to have method names start with a lower case letter, so PrepareStatement becomes prepareStatement

Dave

davejenk at 2007-7-4 13:34:17 > top of Java-index,Database Connectivity,Java Database Connectivity (JDBC)...
# 2

Hi Dave

Thanks a lot for your help.

It wasn't my fault. It was written in a class-like way

where I found it in another forum topic :

PreparedStatement updateStr;

......

updateStr = con.prepareStatement("UPDATE EMPL

SET FirstName=?, LastName= ? FROM EDMP

WHERE LastName = ? "); (by DrClap hours ago)

That is why I was confused..

Thanx again..

Niema

NiemaOsman at 2007-7-4 13:34:17 > top of Java-index,Database Connectivity,Java Database Connectivity (JDBC)...
# 3
Sorry if I mistyped that, but as davejenk says, the API is where you should start. I don't know how I could write Java programs without it.
DrClap at 2007-7-4 13:34:17 > top of Java-index,Database Connectivity,Java Database Connectivity (JDBC)...