Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Updating SQL Fields with single quotes
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Divers
Thread ID:
00715642
Message ID:
00715662
Vues:
23
You mean a string something like:

lcString = "Our members include O'Malley, O'Hara, O'Neil and O'Sullivan"

I created a table named Test with a Descript column. The following works for me:

? SQLEXEC(lnHandle, [update test set descript = '] + STRTRAN(lcString, "'", "''") +['])



>Got ya... But wonder if you wanted to update the field with "O'Malley"? How could you do that? I have long memo fields in SQL that tons of approstrophies and single quotes. I'm bring them into VFP with SQL Select, and want the user to update in an edit field, press , and then I do a SQL UPDATE fuction.
>
>thanks....
Mark McCasland
Midlothian, TX USA
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform