Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to clear out the contents of a View
Message
De
20/01/2005 10:57:23
 
 
À
20/01/2005 10:40:13
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Divers
Thread ID:
00978872
Message ID:
00978895
Vues:
14
Sorry no...

let me explain further.

Underlying table of products
ViewallProducts = a View of All Products - updateable

i have a csv file of products which is to replace the existing table.

i want to try to stick entirely with working with views for when i may upgrade the app to SQL Server or MSDE

So i need to "zap" the products table and import the csv file into it. That i can do and it is straightforward.

I have tried zapping the view and then tableupdate(.t.) but this does not work, the records in the underlying table are left unchanged - regardless of requery etc...


I can Delete all on the view and tableupdate(.t.) this works but seems Very slow ( as i said 3-4 mins for 6.5K records ) - on a very fast pc

deleting each record individually in the view and doing tableudpate(.t.) is even worse.

what i guess i'm looking for is the quickest way of removing all the records in the underlying table but only working through the View.

In the mean time i have set the import routine to work with the underlying tables instead of the views and for example the cleardown and import of products takes around 1- 2 seconds ( if that !)


Hope this helps you help me, let me know if you want more info


TIA

Colin
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform