@@ -1947,7 +1947,7 @@ public int getFoundSetCount(IFoundSetInternal fs)
1947
1947
{
1948
1948
return foundset .getSize ();
1949
1949
}
1950
-
1950
+ long time = System . currentTimeMillis ();
1951
1951
IDataServer ds = application .getDataServer ();
1952
1952
Table t = (Table )foundset .getTable ();
1953
1953
String transaction_id = getTransactionID (t .getServerName ());
@@ -1956,6 +1956,12 @@ public int getFoundSetCount(IFoundSetInternal fs)
1956
1956
QuerySelect selectCountSQLString = sqlString .getSelectCount ("n" , true ); //$NON-NLS-1$
1957
1957
IDataSet set = ds .performQuery (application .getClientID (), t .getServerName (), transaction_id , selectCountSQLString ,
1958
1958
getTableFilterParams (t .getServerName (), selectCountSQLString ), false , 0 , 10 , IDataServer .FOUNDSET_LOAD_QUERY );
1959
+ if (Debug .tracing ())
1960
+ {
1961
+ Debug .trace ("Foundset count time: " + (System .currentTimeMillis () - time ) + " thread: " + Thread .currentThread ().getName () + ", SQL: " + //$NON-NLS-1$//$NON-NLS-2$//$NON-NLS-3$
1962
+ selectCountSQLString .toString ());
1963
+ }
1964
+
1959
1965
if (set .getRowCount () > 0 )
1960
1966
{
1961
1967
Object [] row = set .getRow (0 );
@@ -1980,6 +1986,7 @@ public int getTableCount(ITable table)
1980
1986
{
1981
1987
try
1982
1988
{
1989
+ long time = System .currentTimeMillis ();
1983
1990
IDataServer ds = application .getDataServer ();
1984
1991
String transaction_id = getTransactionID (table .getServerName ());
1985
1992
@@ -1988,6 +1995,11 @@ public int getTableCount(ITable table)
1988
1995
1989
1996
IDataSet set = ds .performQuery (application .getClientID (), table .getServerName (), transaction_id , countSelect ,
1990
1997
getTableFilterParams (table .getServerName (), countSelect ), false , 0 , 10 , IDataServer .FOUNDSET_LOAD_QUERY );
1998
+ if (Debug .tracing ())
1999
+ {
2000
+ Debug .trace ("Table count time: " + (System .currentTimeMillis () - time ) + " thread: " + Thread .currentThread ().getName () + ", SQL: " + //$NON-NLS-1$//$NON-NLS-2$//$NON-NLS-3$
2001
+ countSelect .toString ());
2002
+ }
1991
2003
if (set .getRowCount () > 0 )
1992
2004
{
1993
2005
Object [] row = set .getRow (0 );
0 commit comments