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

Table Buffering Question 1

Status
Not open for further replies.

Scott24x7

Programmer
Jul 12, 2001
2,828
JP
All,
Is it possible to utilize table buffering when just "Browsing" a table with the Browse command? (And then issue say "APPEND BLANK"... I'm trying to test for a bug I have been encountering, and would be easier to test if I can play with the table in an "interactive" simulation...

Any suggestions?



Best Regards,
Scott

"Everything should be made as simple as possible, and no simpler."[hammer]
 

Scott,

Yes. Table buffering (and row buffering too) is relevant whenever a buffered table is updated by any means. That includes programmatic updates (e.g. REPLACE) as well as interactive ones, such as hitting Ctrl+Y while browsing.

In other words, you can put the table in table buffer mode, do a browse, and append a record (APPEND BLANK or Ctrl+Y). The new record will then be in the buffer, from where you can TABLEREVERT or TABLEUPDATE it, in the usual way.

Does that answer your question?

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

My Visual FoxPro site: www.ml-consult.co.uk
 
Mike,
Yes, that's what I'm after, but what I'm not finding in the "Browse" function is how to set the table to Row or Table buffering... Where on a form I can set 0 to 5 for the buffering state, how can I set this for a "Browse"?

As for corrupting data, not worried... just playing against a test table anyway. NEVER work against a live table when just playing with data and behaviros, but good advise none the less!



Best Regards,
Scott

"Everything should be made as simple as possible, and no simpler."[hammer]
 
Ah, found it in the properties under the Data Session window... it's a bit vague there too, but figured it out. Thanks, has made finding my problem a bit easier to figure out how I can address/fix it long term...



Best Regards,
Scott

"Everything should be made as simple as possible, and no simpler."[hammer]
 
Mike,
Cool! That was what I was lookikng for, but the Help on BROWSE didn't mention it as a "See Also"... so I didn't know where else to look! Star for you.



Best Regards,
Scott

"Everything should be made as simple as possible, and no simpler."[hammer]
 
Mike,
Agree with you 100% there... I actually use Optimistic Table Buffering exclusively in my applicatoins...

My problem was related to a RECNO() value of -1, and I was trying to 'Play around' a bit with various conditions, like adding more than 1 row to a table without a TABLEUPDATE(), and when exactly the Negative row conditions were being created. It was causing me some "timing" issues when trying to set record points that were getting established elsewhere in my applicaiton (ThisForm.nCurRec -- a custom property I use...) and then doing to "Clean up", would get "Record out of Range" issues... they are all realted to Delete, Cleanup, row managment in my Table Buffered apps... I think I've got them all sorted now that I've had the chance to "Play and Learn" interactively... I prefer the "Self teach and observation" approach to just throwing out my problem to Tek-Tips, and having someone give me a solution that works, but that I don't understand the WHY behind.

Anyway, thanks to all for assisting in this part of my education! :)



Best Regards,
Scott

"Everything should be made as simple as possible, and no simpler."[hammer]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top