Use the System.currentTimeMillis() to estimate the database's effetive!
Code:
Timestamp st=new Timestamp(System.currentTimeMillis());
customer = (CustomerInfo) sqlMapSE.queryForObject("queryCustomerByname", userName);
Timestamp et=new Timestamp(System.currentTimeMillis());
try
{
out.write("1: queryCustomerByname "+(et.getTime()-st.getTime())+" ");
out.write("/r/n");
out.flush();
}
catch(Exception e)
{
e.printStackTrace();
}
or more simple:
long st=System.currentTimeMillis();
List list = sqlMapSE.queryForList("queryMarketBySector", hm);
long et=System.currentTimeMillis();
try
{
out.write("3: queryMarketBySector "+(et-st));
out.write("/r/n");
out.flush();
}
catch(Exception e)
{
e.printStackTrace();
}