Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Wrapping VFP Views in a SQLServer Transaction
Message
 
To
06/03/2001 15:07:41
Liam O'Hagan
O'Hagan Programming Ltd
Ireland
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00482408
Message ID:
00482975
Views:
13
Liam,
I'm not an expert, but I've been working through these same problems for a client recently.

1) I open a single connection with a small (1 record, 1 field) remote view, then same the connection handle. All my other views and SPT procedures are done with that handle, and SHAREd. The handle value is stored in an application object and used for all forms.

2) SQL Transactions work just fine while you update views. I make sure I have all of the views ready to go before I start the transaction, though, to cut the locking time.

3) I close the connection only when I close the app, but if it's lost I have a function that re-opens it and saves the new handle value.

4) The DBA for my client's SQL-Server said he prefers to have a single connection for each user that stays open as long as the app is loaded instead of re-opening it for each view/SPT command.

They've been testing with 20+ simultaneous users with excellent speed even when all of them are updating files.

HTH
Barbara

>Hi All,
>
>Perhaps someone can clarify this for me ....
>
>If I open a connection to SQL Server and set Transactions to Manual with SQLSetProp(), will subsequently created Remote Views respect that setting? That is, will the views use the open connection (if I specify SHARE in the view creation command) or will they open their own connection (losing the Transaction setting)?
>
>Also, are there any implications in keeping open a connection handle to SQL Server until while my data objects are alive as opposed to disconnecting until such time as I need to send updates.
>
>TIA
>
>Liam
Barbara Paltiel, Paltiel Inc.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform