developing a web application using java. I have SQL queries with more than 40 lines ,using " , "+ at staring an end of query respectively. it is very difficult to convert string as query when i want to do any modifications in both both conversions
it is very difficult to convert string as query when i want to do any modifications This is true. And sad. 40 lines of SQL all written by hand... Feel my condolence... But what is your question?
i am handling already developed project, so now i cant move to struct
1
If your facing trouble in maintaing the sql query then you could try moving to spring JDBC templace where you can store the query in a config/props file with placeholders/bind variables. This significantly reduces the errorneous part of constructing a string query.
it is very difficult to convert string as query when i want to do any modificationsThis is true. And sad. 40 lines of SQL all written by hand... Feel my condolence... But what is your question?