db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sheldon Ross <sr...@simmgene.com>
Subject QueryDataSet constructing takes forever
Date Wed, 21 Oct 2009 21:43:22 GMT
Hello,
The following code produces some interesting results in my system.

            connection = Torque.getConnection(Torque.getDefaultDB());
            PreparedStatement statement = 
connection.prepareStatement(dynamicQuery);
            ResultSet set = statement.executeQuery();
            long startTime = System.currentTimeMillis();
            QueryDataSet dataSet = new QueryDataSet(set);
            log.debug("DDAElapsed time="+ (System.currentTimeMillis() - 
startTime) + " ms");
            return BasePeer.getSelectResults(dataSet);

The actual elapsed time of the query is very small, but it seems to take 
a very long time to create the querydataset.

2009-10-21 15:37:06,969 [TP-Processor3] DEBUG 
org.simmental.datamods.utils.DirectDataAccessor - DDAElapsed time=133 ms
2009-10-21 15:37:06,970 [TP-Processor3] DEBUG 
org.simmental.datamods.om.AnmId - Elapsed time=140 ms

The last is the total elapsed time, so It appears to me like it is 
taking ~ 7ms to do the query, but ~133 ms to construct the querydataset.

Anyone experience anything like this?

Thanks

-- 
Sheldon Ross
Software Development


---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


Mime
View raw message