I have a common class for all DAO's where we will read queries and execute them as below. I will send parameters from DAO to this class.
Connection connection = Queries.getConnection();
String query = Queries.getQuery(queryName);//Queries i will get from xml
PreparedStatement preparedStatement = connection.prepareStatement(query);
what is the best way to set parameters dynamically to prepared Statement in JDBC. I believe, we don't have named parameters concept in JDBC as we have in spring JDBC. We are only simple JDBC in our project.