Specifiying a variable for an sql query in JDBC
Could someone please give me a link on how to create a query in JDBC that gets a variable name in the WHERE statement, or write an example, to be more specific, my code looks something like this:

    private String getLastModified(String **url**) {
					String lastModified = null;
					ResultSet resultSet;
String query = "select LastModified from CacheTable where " + 
					" URL.equals(url)";
					try {
						resultSet = sqlStatement.executeQuery(query);
}

Now I need the syntax that enables me to return a ResultSet object where URL in the cacheTable equals url from the method's argument.

thanks
Specifiying a variable for an sql query in JDBC
===

Could someone please give me a link on how to create a query in JDBC that gets a variable name in the WHERE statement, or write an example, to be more specific, my code looks something like this:

    private String getLastModified(String **url**) {
					String lastModified = null;
					ResultSet resultSet;
String query = "select LastModified from CacheTable where " + 
					" URL.equals(url)";
					try {
						resultSet = sqlStatement.executeQuery(query);
}

Now I need the syntax that enables me to return a ResultSet object where URL in the cacheTable equals url from the method's argument.

thanks