Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How can I update date_field...
Message
 
À
14/12/1999 18:58:45
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Divers
Thread ID:
00303757
Message ID:
00303785
Vues:
17
>While running VFP Update-SQL with VFP database on back-end (server) in order to replace a date_type field with an empty date CTOD("//") I receive an error message. How to do it correctly? May be I need to find a workaround?
>TIA

Ed,

What error message do you receive, is it "Ambiguous date reference"? If it is then you have two choices, one good the other not so good. The good one first;

REPLACE DateField WITH {} && Those are curly braces the date delimiters

The not so good one is;

SET STRICTDATE TO 0 && in the start up prg and the Load of all forms

This one is not so good because the error message you are getting is really a warning that you have a date reference that can change value on you without you knowing it. For example;
SET DATE AMERICAN
?CMONTH(CTOD("01/12/1999")) && shows January

SET DATE BRITISH
?CMNONTH(CTOD("01/12/1999") && Shows ...
Well actually I can't tell what those outputs would be because they depend on the SET DATE setting at the time the code is compiled. The runtime setting has no effect on date literals. The date literals are changed into VFP's internal date format when teh code is compiled.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform