Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Speed problem with VFP 9

Status
Not open for further replies.

svenman

Technical User
Jun 19, 2006
11
US
I have a exe and tables that are stored on a pc in a shared directory nothing special. User run the exe and access the table on that one pc. Anyone running the app on the pc where the exe and table are stored get great response. Any other user can wait up to a minute or more to get a response even if the pc with the app and table are not being accessed. The IT person says it is not a network problem as their is all kind of bandwidth to handle to app.
I have tried running the exe on each client machine and accessing the db on that shared directory with no improvement. The networking environment is the standard MS workgroup network .

I am stumped, anything I can check.

 
Of course local data access is always much faster. Even a Gbit bandwidth is nothing against the speed of a hard drive.

Another problem may be opportunistic locking, also see here:

How's the application designed? Does it acess tables directly? For example: Does it use Tables as Grid's RecordsourceType? This is not really bad, as a grid does only access the records it displays, still a client server conceptual design of the application is recommendable even in a small work group solution with few users.

Bye, Olaf.
 
Olaf

If that reg entry does not exists what is the default.

Thanks but I have already read that posting, I do access the tables via opening them using a

Use xxxx
set order to

statements

Before that I set a default directory depending on weather the tables are present on the c: drive. If the are not present I set the deafult to q: which I have as a map drive to the pc with the tables.
 
If reg entries are not present, the default value is assumed, that is opportunistic locks are ON, eg it's assumed as if
HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Services/LanmanServer/Parameters/EnableOplocks = 1 was present.

You should add the key for the server at the workstation where the tables are actually located on drive C:.

Define HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Services/LanmanServer/Parameters with REG_DWORD EnableOplocks Set as 0
on that machine.

Bye, Olaf.
 
If that does not help to speed up things:

USEing a table will let each user see the whole table, not a filtered set, SET ORDER TO just changes the order of the records.

You will actually not read in the whole table, but as a users scrolls through the grid those records are read, and with opportunistic locks on, that data get's into a local OS file cache and if a second user logs on and USEs that table the workstation with the tables on it's local drive must request all that data back from the client caching it. I don't know, but I would assume the oplock cache is not only caching the few records vfp fetched, it may read in whole files only. So turning that off could be a great help already.

Nevertheless you should only read in partial data, eg. data of last month, data of a certain customer, data belonging to a user, whatever, eg by using parameterized views. That way the app will use less network resources and be more responsive to secondary users anyway.

Bye, Olaf.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top