General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Network:
Windows 2003 Server
>Note for the following that I have no personal experience with client/server; what I tell you is "hearsay". I hope someone corrects me if I make a fundamental mistake in the following presentations.
>
>You don't index the entire table, only the data you have fetched.
>
>I think the main problem is NOT that you are indexing a million records, but that you have to fetch them first.
>
>Client/server logic is very important here; once you switch to client/server, you have to get re-design parts of your application (if you didn't plan for C/S in the first place), and get your users accustomed to new ways of working. You CAN NOT have the users "browse" through a million records, since this will require fetching all of this data first, and this will b e very slow. NOR can you do the equivalent of USE ... / GO BOTTOM (for the entire table), since this will fetch the entire table. Of course, you can fetch a subset of data, and then GO BOTTOM for that subset.
>
>You will have to explain the alternatives to your client: either get all the data at once, and have an excruciatingly slow performance (N.B.: this may also affect other users, since your application will hog the network), or design your application for performance, by providing methods of data retrieval that fetch only the data required. This may be by date, by client, etc.
>
>HTH,
>
>Hilmar.
Thank you Hilmar I got that! I'm using the Remote View's feature for automatic data feching (it can be set in "Advanced options" in View Designer) and it can be set that VFP downloads only first 100 rows from the whole table and the next 100 is downloaded only when the user browse to the 101'th row in the grid etc... So the network traffic is optimised this way and the user can scroll in the grid (using this 100 row "window") without any speed problems and without downloading the whole table thanks to this VFP feature.
My problem is changing the order of this View. I can make several views with different "order by" and requery the suitable View when user changes the order (and download only 100 rows from that view with the automatic fetching mentioned above), but I don't think this is a elegant solution.
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only