Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Index
Message
De
14/03/2007 16:34:48
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
14/03/2007 12:52:18
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Re: Index
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01203424
Message ID:
01203679
Vues:
14
>For me, the real reason not to use DTOC() is that it isn't accurate for sorting when multiple years are involved.

That, too. But whether this matter or not depends on what you use the index for: sorting, I frequently do with SELECT - SQL commands, just before running the report. The index might be used to ensure uniqueness, or to find data.

>As a practical matter, unless you are writing an international application, SET DATE won't change so you don't have to worry about getting different values on different runs. That also wouldn't lead to the problem when building the key. You'ld simply get a wrong result rather than an error.

Even if you program for a single country, you may want to give the user some control, e.g., SET SYSFORMATS.

>My guess is that the error happened because SET CENTURY changed between the time the index was built and the record was added. DTOC() now returns a different length value and the index can't accept it.

Quite possible. I am not sure, though.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform