Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Syntax Error?
Message
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 7
Divers
Thread ID:
01544054
Message ID:
01544140
Vues:
28
>>>>>In the following I am gettting a Syntax Error on the Update command. (I must be going blind.)
>>>>>
>>>>>What am I doing wrong?
>>>>>
>>>>>
>>>>>CREATE CURSOR itest (name c(50), section C(50), value C(250))
>>>>>INSERT INTO itest VALUES ('Test','Main','1')
>>>>>Update iTest set Value="2" where Section="Main" and Name="Test"
>>>>>
>>>>
>>>>You have field named as keyword.
>>>>Change Value to Value1 and you will have no problems.
>>>
>>>Or just prefix Value with the alias (Actually I would argue that all fields should be prefixed with the alias):
>>>
>>>
>>>Update iTest set iTest.Value="2" where iTest.Section="Main" and iTest.Name="Test"
>>>
>>
>>:o)
>>Have one rule:
>>Do not name field or variable that becomes blue when write it in VFP editor :o)))))))))))
>
>But all the good names are blue :)

Many of the PEM are already used as keywords. I have a application called RESET. It appears in blue. But reset is a method associated with the Timer class, and is not a command. The Blue'ing of a keyword has rarely preventted me from using a keyword as a field name. but prefixing them does make better sense.
Greg Reichert
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform