Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Table buffering and SQL
Message
From
15/08/2001 05:53:18
 
 
To
15/08/2001 05:38:14
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00543946
Message ID:
00543947
Views:
15
This message has been marked as a message which has helped to the initial question of the thread.
>Hi All,
>
>I have a problem that is bugging me...
>
>
>Create cursor fred (fld1 n(2),fld2 C(10))
>
>Insert into fred values (1,'Record1')
>Insert into fred values (2,'Record2')
>Insert into fred values (3,'Record3')
>
>=CursorSetProp('Buffering',5)
>
>Go Bott
>Delete
>
>Select * from fred                  && Returns 3 records
>Select * from fred where !deleted() && Returns 3 records <b>(Including the deleted one)</b>
>
>
>The implication from the above is that if a table is buffered then SQL only looks at the committed changes.. is this the case?
>
>In my form I can add or delete records, but before calling the 'add' form I create a cursor with all the existing records to stop duplicate creation.
>The problem comes when I delete a record then try and add the same record again the add routine sees this as a duplicate even though it is deleted.
>
>Suggestions anyone? (we don't have a DBC, so RV's aren't much use) and I was hoping to avoid a custom deleted field.
>
>TIA
>
Will

Yes, SQL will only look for committed records, I had the same thing when I was amending a table and then checking the table using SQL and didn't get the required results until I committed them

Kev
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform