Marc,
OK, I just reran your test programs. I slightly modified one to run 20 cycles and then report the average time.
I copied all the programs to a directory on the server (an old Win 98 PC).
test.exe
test1.exe
planning.dbf
planning.cdx
There are two PCs connected to this server. PC1: XP Home and wired to the server. PC2: XP Pro wireless to the server.
PC2 test.exe
PC1 test1.exe
2.7 seconds average
Then doing the opposite
PC1 test.exe
PC2 test1.exe
6.5 seconds average
Then without running test.exe:
PC1 test1.exe 2.6 seconds average
PC2 test1.exe 6.6 seconds average
Summary
PC1 (wired)
With test.exe 2.7 seconds
Without test.exe 2.6 seconds
PC2 (wireless)
With test.exe 6.5 seconds
Without test.exe 6.6 seconds
There is no significant speed change in test1.exe when running test.exe on another PC.
If you want to run my EXEs on your system, let me know and I will email them to you. Send me your email address (jbott at compuserve dot com).
Below is my modified test1.prg.
Regards,
James
/*
Program: Test1.prg
Purpose: Test for Marc Vanzegbroeck
Problem: Slowdown on network when 2nd PC opens file
*/
#INCLUDE "FiveWin.ch"
REQUEST DBFCDX
FUNCTION test1()
local oWnd, i
local t := seconds()
local vstruct:={}
local nSum:=0,j
field nr
RDDSETDEFAULT("DBFCDX")
IF !file('planning.dbf')
aadd(vstruct,{'NR','N',10,0})
dbcreate('planning',vstruct)
use planning new shared
FOR i=1 to 1000000
appe blank
repl nr with i
NEXT
index on str(nr) tag test
ENDIF
use planning new shared
ordSetFocus( 'TEST' )
// Average 20 runs
for j:=1 to 20
T := seconds()
FOR i = 1 to 1000
seek str(92*i,10)
NEXT i
nSum:= nSum + seconds()-t
next j
msgInfo( nSum/20, "Average of 20 cycles")
RETURN nil