Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Indexing a file?
Message
De
18/10/2002 09:31:16
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
18/10/2002 09:24:17
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00712791
Message ID:
00712837
Vues:
8
>>Second, using quotation marks, you make sure that an actual tag is selected, NOT a field or other expression.
>
>Yes, that would be a problem too IF the unquoted name used was numeric AND its value was within the count of TAGs in the table.

Exactly. Now, this situation may be a little unlikely, but not too much so. Precisely this situation happened to me some years ago, and it took me a while to debug.

>I shall now start using quotes around TAG names.

Now, it is my habit to always use quotation marks, just in case. I recommend it as a safer programming practice. As a comparison, it is usually recommended to declare all your variables local (whenever it makes sense to do so), even if omitting LOCAL doesn't create conflicts in most cases (I got into trouble with variable "i" a few years ago, used in: FOR i = 1 to ...)

Hilmar.
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