For the assessment of embedded SQL in Java application Ispirer uses tools Visual Studio or free toolkit jEdit. The assessment process is based on the finding of regular expressions.
In this conversion task we need convert only Embedded SQL from source database to target database and change connection string to database. Firstly, we need to identify how many LOC for database APIs functions/statements and embedded SQL are used in the source application? Using this information the estimations are provided. For the assessment of database APIs functions/statements and embedded SQL Ispirer uses tools Visual Studio or free toolkit jEdit (http://www.jedit.org/). How to assess?
Usually every line is ends with end line symbol “\n”, so when we search for this symbol in the whole project we can count LOC for the all files.
Results will look like in next screen:
Depends on the project we need to find all places that corresponds to creating statements and executing it if we need to change it during migration. In common we need to find prepareStatement, prepareCall, but if you use different API we can count it too but with different RegExp.
1. Search for .prepareStatement
2. Search for .prepareCall
The most valuable information for us is number of the DML statements and procedure’s calls. Using jEdit and regular expressions from bellow, we can count approximate number of such statements.
1. ”[ \t]*SELECT
2. ”[ \t]*INSERT
3. ”[ \t]*DELETE
4. ”[ \t]*UPDATE
NOTE: Depending on Database call statements could be different, so for each case we build different regular expression.
© 1999-2017, Ispirer Systems Ltd.
All Rights Reserved. Privacy Statement