Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Excel export
Message
De
09/09/2011 05:45:43
 
 
À
09/09/2011 05:32:19
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01523064
Message ID:
01523075
Vues:
94
This message has been marked as the solution to the initial question of the thread.
>>>>>I have a table with 1166 records. When I export it to MS Excel, it results 1140 records.
>>>>>What can cause the reduced record number?
>>>>
>>>>How you export data?
>>>
>>>File -> Export -> select the place where to export.
>>>When I insert it to another table it behaves the same:
>>>
>>>INSERT INTO bpeng_m SELECT * FROM bp_eng 
>>>
>>
>>Maybe you have 26 deleted records and your SET DELETED is ON?
>Yes, you're right. But...
>When i set "SET DELETED OFF", I can see the 26 deleted records in the table.
>Why does VFP calculate the deleted records in the number of the total records when they have been deleted?
>Or is there a way to set it to show the correct record number?


Because they are in table :-)
Also, number of records are stored in DBF header. When you use RECCOUNT() function VFP didn't calculate number of records, it just read their number from DBF header.
Nom you can't set it to show the nimber you want, but you could calculate non deleted records by youself and show them to the user:
SET DELETED ON
COUNT TO lnRecNo
? lnRecNo
** or
SELECT COUNT(*) FROM YourTable INTO ARRAY laRecNo
? laRecNo[1]
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform