Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL Server Based Application Development
Message
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00635558
Message ID:
00635588
Views:
12
>I am about to start my very first SQL Server based Application. I would like to get your suggestion on what is a good approach for connectivity?
>? Should I have a exclusive connection for every table?
>? Should I have a connection per form?
Try to share the connection as much as possible. You can share connection among remote views with ShareConnection property. For SQL pass-through you just need to use the same connection on every SQLExec.


>? Should I open a connection, fetch the data/write data and close the connection?
That's up to you. In theory you should do that (release the connection as soon as possible.) If you do that, you cannot use remote views since they need to be connected to the back end all the time. In practice, depending on the number of users you can probably get by using a single connection by user (as mentioned above.)

Take a look at SQL pass-through in addition to remote views. You can use remote view for some stuff and SQL pass-through for other areas.

Also, I second the book that Sergey mentioned. It is very good. There is also a chapter on VFP help about client/server application that is worth a look.
Hector Correa
Previous
Reply
Map
View

Click here to load this message in the networking platform