Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
V6s5 - REQUERY() a view for a given SELECT no. of recs
Message
 
To
21/04/2004 08:48:06
Mike Yearwood
Toronto, Ontario, Canada
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00895276
Message ID:
00897114
Views:
23
Out of town for a week, try it later and then let you know.

>There is a cursor created by a view. The SELECT in BuildTree() reads from that cursor? You are deleting a record in that cursor and doing tableupdate. Then you run BuildTree() again?
>
>Like this?
>
>
SELECT ;
>    Cmp_Name ;
>  FROM ;
>    Companies ;
>  WHERE ;
>    UPPER(cmp_name) = "A" ;
>  INTO CURSOR step1 ;
>  NOFILTER READWRITE
>?RECCOUNT()
>
>DELETE FOR MOD(RECNO(),10)=0
>
>*Simulate SQL in BuildTree()
>lcSetDeleted = SET("DELETED")
>SET DELETED ON
>SELECT Cmp_Name FROM STEP1 INTO CURSOR STEP2
>SET DELETED &lcSetDeleted.
>?RECCOUNT()
>
>If SET DELETED is OFF, the number of records in Step2 is the same as Step1. If SET DELETED is ON the number of records will be less in Step2. It is better to use SET DELETED before the SQL than to use NOT DELETED() in the SQL.
>
>
>>Hi Mike
>>
>>>Add the NOFILTER keyword to the end of the SQL command.
>>
>>Though this keyword I could not find in the help for SELECT - SQL I was worried that it would raise an error. Sorry no change. I put in a browse on the remote view in this buildtree() method that houses the SELECT statement and yet the deleted record shows in the browse window.
>>
>>My framework CodeBook has Transactions, will that affect results?
>
>No. None of this should be happening during a transaction.
Regards
Bhavbhuti
___________________________________________
Softwares for Indian Businesses at:
http://venussoftop.tripod.com
___________________________________________
venussoftop@gmail.com
___________________________________________
Previous
Reply
Map
View

Click here to load this message in the networking platform