Emptying tables..

Ruslan Zasukhin sunshine at public.kherson.ua
Mon Jul 14 08:22:58 CDT 2003


on 7/13/03 17:29, Chuck at rwc1717 at shaw.ca wrote:

> Hi Ruslan:
> I decided to use the SQLExecute("DELETE from T").
> ie:
> 
> Dim i as integer
> i = mDB.SQLExecute("DELETE from Table1")
> mDB.Flush
> 
> I tried to use the mDB.boTable1.DeleteAll() but kept being told that deleteall
> is 
> not identifiable.
> 
> If I use a VCursor as the base object and use
> 
> Dim vc as VCursor
> dim res as boolean
> vc =Nil
> vc = mDB.SQLSelect("select * from Table1")
> res = vc.DeleteAll
> mDB.Flush
> 
> ......so this must be the baseobject method????
> 
> Both methods accomplish the same results but it would seem that the first
> code would be faster...cleaner for memory....Given I must do this to 3 tables
> in a 
> row. I also assume that flushing between these global deletes would be good
> idea.
> 
> Are these assumptions correct?

Chuck,

Just I did not know what API you use.
If you check docs of V4RB you will find

    VBaseObject.DeleteAllRecords()

Try this function.

It is fastest. Although SQLExecute("DELETE from T") also use it I think.

-- 
Best regards,
Ruslan Zasukhin      [ I feel the need...the need for speed ]
-------------------------------------------------------------
e-mail: ruslan at paradigmasoft.com
web: http://www.paradigmasoft.com

To subscribe to the Valentina mail list go to:
http://lists.macserve.net/mailman/listinfo/valentina
-------------------------------------------------------------



More information about the Valentina mailing list