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 Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Where to find SPT sample codes

Status
Not open for further replies.

ArthurLiu88

Programmer
Aug 5, 2006
16
CN
Hi
I'm a beginner for SPT. Does anyone can help where I can find out the sample codes including navigate, add, edit and delete, just like the 'Tastrade' in the VFP.

Many thanks
Arthur
 
Thanks Mike

When I first learn VFP, I read very line of the sample APP 'Tastrade' in the VFP installed path. And then I write my own APP almost 9M, it works well when it's only 10 users (using 'USE mytable SHARED'). Now I will have 50 users, I have to choose SQL and rewrite my codes.

My question are
1. What's the better way to update table, INSERT-SQL or buildup the updateable cursor
2. In VFP, I can use SKIP to navigate the table, how can I do it in SQL. Do I have to SQLEXEC(nHandle, "SELECT * FROM mytable", "mycursor") everytime?
3. When Adding, Editing or Deleting record, I update the CURSOR first and then update table in Server, or I update the table in Server directly.

Many thanks
Arthur Liu
 
What's the better way to update table, INSERT-SQL or buildup the updateable cursor

A very difficult question because so much depends on the power of the server and the speed of the network. If you write some speed tests then you'll know the best answer for your own circumstances.

Geoff Franklin
 

Arthur,

It also depends on your personal preferences and style of programming. There's no perfect answer to your questions.

Why not try different approaches and see which ones you feel comfortable with, and which ones work best for you. If nothing else, that will give you some experience of the various techniques.

Mike


__________________________________
Mike Lewis (Edinburgh, Scotland)

My Visual FoxPro site: www.ml-consult.co.uk
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top