Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Conditionally updating fields
Message
 
À
13/10/2016 04:12:33
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP2
Database:
MS SQL Server
Divers
Thread ID:
01641827
Message ID:
01641866
Vues:
40
>Hi Frank:
>
>Your SQL is erroneous, because ISNULL() only accepts 1 parameters and returns True/False, so in this case Thierry was right in using NVL(), but at the cost of always replacing the value (with the actual one or the new one, whatever)
>
>But if you are processing to much data and want the best performance, then Dragan's suggestion of building your UPDATE (with a series of IF..ENDIF for each field) is the best performing and does not add any noticeable cost of maintenance.


Used database is SQL Server so ISNULL() have the right syntax.
In TSQL ISNULL() function is equal to VFP NVL() function.
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